[issue9287] Minor fix in test_file2k.OtherFileTests.testOpenDir

2010-09-23 Thread Hirokazu Yamamoto
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: I've committed your fix in r84975. Thank you. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue9925] Idle doesn't launch

2010-09-23 Thread Stephan Bellegy
Stephan Bellegy stephan.bell...@gmail.com added the comment: it is reproductible. At first, Python 2.6.? was installed. i tried to install 2.7 and got the problem uninstalled 2.7 tried 2.6.6 and got the problem then google, delete dir and got it running --

[issue9927] Leak around GetFinalPathNameByHandle (Windows)

2010-09-23 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: The tests pass here, but I haven't thoroughly reviewed the patch yet. After a quick glance it generally looks ok, although I wish we didn't have so much duplication. -- ___ Python tracker

[issue1675951] Performance for small reads and fix seek problem

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Thank you very much! I have kept the second approach (use PaddedFile at all times), since it is more regular and minimizes the probability for borderline cases. As for the supposed performance slowdown, it doesn't seem significant. On large

[issue9360] nntplib cleanup

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Yes, unescaped utf-8 is explicitly allowed in headers by RFC 3977: The content of a header SHOULD be in UTF-8. However, if an implementation receives an article from elsewhere that uses octets in the range 128 to 255 in some other

[issue9272] CGIHTTPServer poisons os.environ

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Anatoly, last we heard you did not wish to sign the contributor agreement and so were not submitting patches. We are respecting your wishes by not applying this. Have you changed your mind? --

[issue9928] weird oddity with bz2 context manager

2010-09-23 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: I haven't investigated but this is weird (especially the fact that it doesn't *always* happen). There might be a problem with SETUP_WITH or perhaps the method cache: import bz2 f = bz2.BZ2File('foo.bz2', 'wb') with f: pass ... Traceback

[issue9928] weird oddity with bz2 context manager

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Actually, it is because bz2 doesn't call PyType_Ready() but instead sets some field manually. Perhaps we could have a guard somewhere that raises a fatal error when a C extension type hasn't been properly readied? In the meantime, this patch

[issue9928] weird oddity with bz2 context manager

2010-09-23 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: 2010/9/23 Antoine Pitrou rep...@bugs.python.org: Antoine Pitrou pit...@free.fr added the comment: Actually, it is because bz2 doesn't call PyType_Ready() but instead sets some field manually. Perhaps we could have a guard somewhere

[issue9929] subprocess.Popen unbuffered not work (windows)

2010-09-23 Thread Hirokazu Yamamoto
New submission from Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp: Following script hangs on Python3.x. from subprocess import * import sys p = Popen([sys.executable, -c, import sys; print(sys.stdin.read(1))], stdin=PIPE) p.stdin.write(b'x') p.wait() This is because unbuffered functionality

[issue9929] subprocess.Popen unbuffered not work (windows)

2010-09-23 Thread Hirokazu Yamamoto
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: Interestingly, following code also hangs. Maybe I'm misunderstanding the meaning of *bufsize* from subprocess import * import sys p = Popen([sys.executable, -c, import sys; print(sys.stdin.read(1))], stdin=PIPE)

[issue9272] CGIHTTPServer poisons os.environ

2010-09-23 Thread anatoly techtonik
anatoly techtonik techto...@gmail.com added the comment: I still haven't received answers on the licensing questions in developer's mailing list. After the amount of negative feedback received I decided not to continue. But I am still interested in constructive discussion to get satisfying

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Mark Shannon
New submission from Mark Shannon ma...@dcs.gla.ac.uk: Attached program fails. See comments in file for details and possible diagnosis -- files: binary_op_mimic.py messages: 117216 nosy: Mark.Shannon priority: normal severity: normal status: open title: Incorrect semantics of __radd__

[issue9272] CGIHTTPServer poisons os.environ

2010-09-23 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: ISTM that the attached patch is trivial enough not to require any contributor agreement or copyright assignment, at least if we change Ma Test CGI Server v1.0 to something neutral. -- ___ Python

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Could you post some simple examples and an explanation of what you think the problem is? I have no clue what problem your code is trying to show just by looking at it. (Maybe it will be clear to someone else, but still, simple

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: This is indeed weird. PyNumber_Add ends up calling compare_add with the float as its first argument, which is impossible to do from Python. And the wrap_binaryfunc_r check for subtypes means that compare.__radd__ claims it doesn't support

[issue9921] os.path.join('x','') behavior

2010-09-23 Thread Brian Brazil
Brian Brazil brian.bra...@gmail.com added the comment: The behaviour is a bit more nuanced: os.path.join('x', '') 'x/' os.path.join('x', '', 'y') 'x/y' os.path.join('x', '', 'y', '', '') 'x/y/' os.path.join('', 'x') 'x' I'm unsure how to word this best, maybe non-trailing empty paths are

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: If I understand correctly, the complaint is that (for example) in Python 3.x, we have: Python 3.1.2 (r312:79147, Aug 20 2010, 20:06:00) [GCC 4.2.1 (Apple Inc. build 5664)] on darwin Type help, copyright, credits or license for more

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Mark Dickinson
Changes by Mark Dickinson dicki...@gmail.com: -- versions: +Python 3.2 -Python 2.5, Python 2.6, Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9930 ___

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: PyNumber_Add ends up calling compare_add with the float as its first argument, which is impossible to do from Python. [Assuming you mean complex_add.] I think this bit is expected, though. complex_add (or float_add, or whatever) provides

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Hmm, not sure. I'm referring to Objects/abstract.c, binary_op1, which tries to call both slotv and slotw. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9930

[issue9815] test_tarfile sometimes ends with error Cannot remove dir

2010-09-23 Thread Hirokazu Yamamoto
Changes by Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp: -- keywords: +needs review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9815 ___ ___

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: It looks like Mark is right: the wrap_binaryfunc_r subtype check should just be removed. The corresponding check in 2.x only occurs for types which don't have the Py_TPFLAGS_CHECKTYPES flag set. As of 2.7, *all* of the numeric types have

[issue9930] Incorrect semantics of __radd__ method for builtin types

2010-09-23 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: That's encouraging. I would suggest making this fix; the fact that Jython and IronPython also get this right is another reason. -- ___ Python tracker rep...@bugs.python.org

[issue9808] Implement os.getlogin on Windows

2010-09-23 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: Committed in r84983. Thanks! -- components: +Extension Modules -Library (Lib) resolution: accepted - fixed stage: patch review - committed/rejected ___ Python tracker rep...@bugs.python.org

[issue9928] weird oddity with bz2 context manager

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Patch committed in r84980 (3.2), r84981 (3.1) and r84982 (2.7). -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9928

[issue9815] test_tarfile sometimes ends with error Cannot remove dir

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Adding Michael for review of py3k_fix__AssertRaisesContext.patch. -- nosy: +michael.foord ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9815

[issue9931] test_ttk_guionly hangs on XP5

2010-09-23 Thread Hirokazu Yamamoto
New submission from Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp: test_ttk_guionly hangs on x86 XP5 buldbot. But it doesn't hang on test_tk. Former shows widget but latter doesn't on my machine. http://www.python.org/dev/buildbot/all/builders/x86%20XP-5%203.x/builds/1348/steps/test/logs/stdio

[issue9932] List of sets initialization behavior problems

2010-09-23 Thread Adam Nemecek
New submission from Adam Nemecek adamneme...@gmail.com: I'm not sure if this is the intended behavior, but it seems unusual to me. a = [set([]) for i in range(2)] evaluates to a list [set([]),set([])] and b= 2*[set([])] evaluates to [set([]),set([])]. Nothing wrong here. Nevertheless, if I do

[issue9790] ntpath contains imports inside functions

2010-09-23 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: Committed to py3k in r84988 using Nick's second suggestion. -- resolution: - fixed stage: needs patch - committed/rejected ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9790

[issue9808] Implement os.getlogin on Windows

2010-09-23 Thread Jon Anglin
Changes by Jon Anglin jang...@fortresgrand.com: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9808 ___ ___

[issue9790] ntpath contains imports inside functions

2010-09-23 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9790 ___ ___ Python-bugs-list

[issue9401] automatically try forward operations when reverse operations are NotImplemented

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: No, but you could bring it up on python-ideas. (It would have to wait until after the moratorium in any case.) -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org

[issue9905] subprocess.Popen fails with stdout=PIPE, stderr=PIPE if standard descriptors (0, 1, 2) are closed.

2010-09-23 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- nosy: +gregory.p.smith ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9905 ___ ___

[issue1385] hmac module violates RFC for some hash functions, e.g. sha512

2010-09-23 Thread Jesús Cea Avión
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1385 ___ ___ Python-bugs-list mailing list

[issue2052] Allow changing difflib._file_template character encoding.

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I believe that charset is the standard default for html, which would make this a feature request. -- assignee: tim_one - nosy: +r.david.murray stage: unit test needed - needs patch type: behavior - feature request versions:

[issue9932] List of sets initialization behavior problems

2010-09-23 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: This is well defined in Python and will not change. -- nosy: +eric.smith resolution: - rejected stage: - committed/rejected status: open - closed type: - feature request ___ Python tracker

[issue8879] Implement os.link on Windows

2010-09-23 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: Here's a patch of the functionality. The doc change is small and easy, I'll add it shortly. One oddity is that os.path.samefile is False for a link and its source, but True for a symlink and its source. I find that to be quite odd, but stepping

[issue2005] posixmodule expects sizeof(pid_t/gid_t/uid_t) = sizeof(long)

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: It appears as though this was fixed as part of issue 1983. Antoine, can you confirm that? -- nosy: +pitrou, r.david.murray -BreamoreBoy versions: +Python 2.7, Python 3.1, Python 3.2 -Python 2.6, Python 3.0

[issue8879] Implement os.link on Windows

2010-09-23 Thread Hirokazu Yamamoto
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: With following implementation, issamefile return True for hard link. I heard GetFinalPathNameByHandle returns different paths for hard links. import nt, os def issamefile(path1, path2): ... fd1 = os.open(path1, os.O_RDONLY)

[issue3873] Unpickling is really slow

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Here is a fixed version of Victor's bench (didn't work on 2.x). -- Added file: http://bugs.python.org/file18983/bench_pickle.py ___ Python tracker rep...@bugs.python.org

[issue6706] asyncore's accept() is broken

2010-09-23 Thread Dave Malcolm
Dave Malcolm dmalc...@redhat.com added the comment: giampaolo: did you ever rewrite the patch? For reference to other users: http://code.google.com/p/pyftpdlib/source/browse/trunk/pyftpdlib/ftpserver.py Note the complexity of the two handle_accept implementations in that file; both of them

[issue3873] Unpickling is really slow

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: And here is new performance patch (Victor's patch was outdated because of heavy changes incorporated from Unladen Swallow). Results of bench_pickle.py are as follows: * Python 2.7 (cPickle): Protocol 0 - dump: 189.8 ms - load (seekable=False):

[issue9905] subprocess.Popen fails with stdout=PIPE, stderr=PIPE if standard descriptors (0, 1, 2) are closed.

2010-09-23 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: issue6610 looks very similar. issue9074 may also be related. -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9905

[issue2005] posixmodule expects sizeof(pid_t/gid_t/uid_t) = sizeof(long)

2010-09-23 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The pid_t issue was fixed but not uid_t/gid_t. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2005 ___

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread Kamil Kisiel
New submission from Kamil Kisiel kisi...@users.sourceforge.net: The library documentation (http://docs.python.org/library/os.html) states: os.EX_NOTFOUND Exit code that means something like “an entry was not found”. Availability: Unix. New in version 2.3. However, on both my Linux and OS X

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread Kamil Kisiel
Kamil Kisiel kisi...@users.sourceforge.net added the comment: That should have read Linux and OS X installs of *Python*. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9933 ___

[issue9790] ntpath contains imports inside functions

2010-09-23 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: Nick noticed another issue with this, and it actually won't work on pre-Vista versions since we load GetFinalPathNameByHandle at runtime, which is why we had that NotImplementedError. Attaching a patch which should handle this. We only try the

[issue9934] Python Docs Typo

2010-09-23 Thread Retro
New submission from Retro vinet...@gmail.com: http://docs.python.org/distutils/sourcedist.html#manifest-related-options Please visit the above link and note the typo in: -o is a sortcut for --manifest-only. Should be: -o is a shortcut for --manifest-only. The word sortcut is a typo. Please

[issue4661] email.parser: impossible to read messages encoded in a different encoding

2010-09-23 Thread Dan Buch
Changes by Dan Buch daniel.b...@gmail.com: -- nosy: +meatballhat ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4661 ___ ___ Python-bugs-list

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: The following code exists in Modules/posixmodule.c 8167 /* These come from sysexits.h */ ... 8216 #ifdef EX_NOTFOUND 8217 if (ins(d, EX_NOTFOUND, (long)EX_NOTFOUND)) return -1; 8218 #endif /* EX_NOTFOUND */ sysexits.h on my Mac has no

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Perhaps this constant existed at some point on some linux systems...google found one comment about it referencing posix.2. I also found it mentioned in a specific version of sendmail, and in bash. When it appears it seems to most

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: s/linux/unix/ -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9933 ___ ___

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: +1 for removing it from the docs. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9933 ___ ___

[issue9935] Faster pickling of instances

2010-09-23 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: This is a bunch of assorted optimizations which make pickling of user-defined classes quite a bit faster. Example on a minimal instance: $ python -m timeit -s import pickle; import collections, __main__; __main__.X=type('X', (), {}); x=X()

[issue6608] asctime does not check its input

2010-09-23 Thread MunSic JEONG
MunSic JEONG rus...@gmail.com added the comment: Thank you for a kind guidance. I uploaded patch with - function name checktm - add comment above gettmarg - move comment in checktm to (above function signature) - change comment little bit to mention issue6608 - { on new line

[issue9783] _elementtree.c warnings under 64-bit Windows

2010-09-23 Thread Jon Anglin
Jon Anglin jang...@fortresgrand.com added the comment: issue9783.diff provides a patch that will compile clean on 32 and 64 bit Windows systems. I tried to avoid explicit casts where I could, but it was not always possible. I have ported a lot of my company's code to 64 bit (all Windows

[issue2209] mailbox module doesn't support compressed mbox

2010-09-23 Thread Skye
Changes by Skye sky...@gmail.com: -- nosy: +skyepn ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2209 ___ ___ Python-bugs-list mailing list

[issue9784] _msi.c warnings under 64-bit Windows

2010-09-23 Thread Jon Anglin
Jon Anglin jang...@fortresgrand.com added the comment: issue9784.diff contains a patch that compiles clean on 32 and 64 bit Windows. This patch is exactly what Amaury Forgeot d'Arc recommended in msg115750. -- keywords: +patch Added file: http://bugs.python.org/file18989/issue9784.diff

[issue6608] asctime does not check its input

2010-09-23 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- nosy: -brett.cannon ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6608 ___ ___ Python-bugs-list

[issue9936] trace misreports missing lines

2010-09-23 Thread Alexander Belopolsky
New submission from Alexander Belopolsky belopol...@users.sourceforge.net: With the attached traceme.py, $ python -m trace -m -s -c traceme.py lines cov% module (path) 250% traceme (traceme.py) $ cat traceme.cover x = (1, 2, 1: 3) This is wrong

[issue9936] trace misreports missing lines

2010-09-23 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: I am attaching a patch that fixes this issue. Need to add a unit test. -- assignee: - belopolsky components: +Library (Lib) keywords: +patch stage: - unit test needed type: - behavior versions: +Python 3.2

[issue9936] trace misreports missing lines

2010-09-23 Thread Alexander Belopolsky
Changes by Alexander Belopolsky belopol...@users.sourceforge.net: -- nosy: +eli.bendersky, terry.reedy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9936 ___

[issue1794] Hot keys must work in any keyboard layout

2010-09-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: it does seem that the consensus is that this is not a generally desirable feature. -- nosy: +r.david.murray -BreamoreBoy resolution: - rejected stage: - committed/rejected status: open - closed

[issue1763] Winpath module - easy access to Windows directories like My Documents

2010-09-23 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- status: closed - languishing ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1763 ___ ___

[issue9936] trace misreports missing lines

2010-09-23 Thread Alexander Belopolsky
Changes by Alexander Belopolsky belopol...@users.sourceforge.net: -- versions: +Python 2.7, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9936 ___

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread Kamil Kisiel
Kamil Kisiel kisi...@users.sourceforge.net added the comment: I mostly wanted to just report the issue rather than propose a solution, so I'm in favor of whatever everyone feels is best. As for how I came across the issue, it was mostly curiosity, I wanted to see the numerical value of all

[issue7519] ConfigParser can't read files with BOM markers

2010-09-23 Thread Andrew Ziem
Changes by Andrew Ziem ahz...@gmail.com: -- nosy: +AndrewZiem ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7519 ___ ___ Python-bugs-list mailing

[issue459007] Document sys.path on Windows

2010-09-23 Thread MunSic JEONG
Changes by MunSic JEONG rus...@gmail.com: -- nosy: +ruseel ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue459007 ___ ___ Python-bugs-list mailing

[issue9933] os module does not have the documented EX_NOTFOUND attribute

2010-09-23 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: I fail to see the issue. The documentation clearly says, above the block of all the EX_* constants: Note Some of these may not be available on all Unix platforms, since there is some variation. These constants are defined where they are

<    1   2