[issue992389] attribute error due to circular import

2011-10-15 Thread Nick Coghlan
Nick Coghlan added the comment: Changed the issue title to state clearly that the core issue is with circular imports that attempt to reference module contents at import time, regardless of the syntactic form used. All of the following module level code can fail due to this problem: from

[issue13187] relative imports don't work when circular

2011-10-15 Thread Nick Coghlan
Nick Coghlan added the comment: This is the same problem that all "from x import y" circular imports have - it isn't specific to relative imports. Closing as a duplicate of issue 992389 -- resolution: -> duplicate status: open -> closed superseder: -> attribute error after non-from

[issue13177] Avoid chained exceptions in lru_cache

2011-10-15 Thread Raymond Hettinger
Raymond Hettinger added the comment: Sorry, I'm not going to introduce a possible race condition because you find try/except to be less elegant than an if-contains test. Also, I want to keep the current behavior of calling hash only once. Your original complaint is valid though, so I'll go

[issue13153] IDLE crash with unicode bigger than 0xFFFF

2011-10-15 Thread Terry J. Reedy
Terry J. Reedy added the comment: > I'm not sure what you mean with "turn them into bug reports" though. In about the last month, there have been, I think, 4 reports about IDLE crashing (quitting unexpectedly with no error traceback). I would consider it preferable if it quit with an error tr

[issue7317] Display full tracebacks when an error occurs asynchronously

2011-10-15 Thread Julian
Julian added the comment: I wish there was a less instrusive of saying "+1. I'm happy. Thanks." than posting a whole comment, but until then: +1. I'm happy. Thanks. (I haven't inspected the code - just based on the description.) -- ___ Python trac

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

2011-10-15 Thread Eric G. Barron
Changes by Eric G. Barron : -- nosy: +ericography ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.p

[issue13188] generator.throw() ignores __traceback__ of exception

2011-10-15 Thread Antoine Pitrou
New submission from Antoine Pitrou : In the following code, the original traceback attached to the exception thrown into the generator is ignored: def gen(): try: yield except: raise g = gen() try: 1/0 except ZeroDivisionError as v: g.throw(v) But if you repla

[issue13187] relative imports don't work when circular

2011-10-15 Thread Meador Inge
Changes by Meador Inge : -- nosy: +meador.inge ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue13184] Multi-layered symlinks to python cause runtime error. sys.path is malformed.

2011-10-15 Thread Jason Howlett
Jason Howlett added the comment: Here is a proposed patch that solves the problem I described. Hopefully someone more familiar with Module/gethpath.c can make sure that it is ok and make improvements if needed. -- keywords: +patch title: Multi-layered symlinks cause runtime error. sy

[issue13187] relative imports don't work when circular

2011-10-15 Thread Eric Snow
Changes by Eric Snow : -- nosy: +eric.snow ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue13153] IDLE crash with unicode bigger than 0xFFFF

2011-10-15 Thread Ezio Melotti
Ezio Melotti added the comment: This can also be reproduced by doing: >>> print('\U000104a2'[0]) � and then copy/pasting the lone surrogate. The traceback is: [...] File "C:\Programs\Python32\Lib\tkinter\__init__.py", line 1009, in mainloop self.tk.mainloop(n) UnicodeDecodeError: 'utf8'

[issue13187] relative imports don't work when circular

2011-10-15 Thread Florent Xicluna
Changes by Florent Xicluna : -- nosy: +flox ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue13187] relative imports don't work when circular

2011-10-15 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +brett.cannon ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.

[issue13187] relative imports don't work when circular

2011-10-15 Thread Antoine Pitrou
New submission from Antoine Pitrou : This is, to say the least, annoying. $ mkdir mypackage $ touch mypackage/__init__.py $ echo "from . import b" > mypackage/a.py $ echo "from . import a" > mypackage/b.py $ ./python -c "import mypackage.a" Traceback (most recent call last): File "", line 1, i

[issue13153] IDLE crash with unicode bigger than 0xFFFF

2011-10-15 Thread Ezio Melotti
Ezio Melotti added the comment: > Ezio, do you know anything about these speculations? Assuming that the non-BMP character is represented with two surrogates (\ud801\udca2) and that _tkinter tries to decode them independently, the error message ("invalid continuation byte") would be correct.

[issue7317] Display full tracebacks when an error occurs asynchronously

2011-10-15 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue12997] sqlite3: PRAGMA foreign_keys = ON doesn't work

2011-10-15 Thread Mark Bucciarelli
Mark Bucciarelli added the comment: Something strange is going on. I just built pysql 2.6.3 from source, and now my unit test gives the expected "IntegrityError: foreign key constraint failed" message. poq, what do you get when you run this script: import sqlite3 print "sqlite3.version_info

[issue13139] multiprocessing.map skips finally blocks

2011-10-15 Thread Jesse Noller
Jesse Noller added the comment: Antoine is correct, as he usually is. This is more of a documentation issue than bug. -- ___ Python tracker ___

[issue13186] instance_ass_item() broken in classobject.c (Py2.7)

2011-10-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 418fbf1af875 by Benjamin Peterson in branch '2.7': PyEval_CallObject requires a tuple of args (closes #13186) http://hg.python.org/cpython/rev/418fbf1af875 -- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected status: ope

[issue13179] IDLE uses common tkinter variables across all editor windows

2011-10-15 Thread Roger Serwy
Roger Serwy added the comment: For Code Context, the behavior is a bug since the menu item check can be changed independently of the actual status of Code Context. As far as I can tell, flist.vars mostly contains variables created by EditorWindow.py's "get_var_obj". A quick grep for ".vars"

[issue12406] msi.py needs updating for Python 3.3

2011-10-15 Thread Vinay Sajip
Vinay Sajip added the comment: Another problem in creating the MSI is that Lib\test\keycert.passwd.pem and Lib\test\keycert.pem both lead to a short name of 'KEYCERT.PEM', which is causing an assertion failure in msilib.Directory.make_short(). The other clashing pair is Lib\test\ssl_key.passw

[issue13172] pysetup run --list-commands fails with a traceback

2011-10-15 Thread Paul Moore
Paul Moore added the comment: I suppose so, yes. But it feels symptomatic of a general lack of clean error handling, which I think should be fixed :-( -- ___ Python tracker ___

[issue13172] pysetup run --list-commands fails with a traceback

2011-10-15 Thread Vinay Sajip
Vinay Sajip added the comment: > so I guess that handling the issue gracefully isn't really important. Then should this issue be closed? -- nosy: +vinay.sajip ___ Python tracker __

[issue13175] packaging uses wrong line endings in RECORD files on Windows

2011-10-15 Thread Paul Moore
Paul Moore added the comment: Windows 7, 32 bit. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue10653] test_time test_strptime fails on windows

2011-10-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: Crashes on the Windows buildbots: f:\dd\vctools\crt_bld\self_x86\crt\src\strftime.c(832) : Assertion failed: ( "Invalid format directive" , 0 ) f:\dd\vctools\crt_bld\self_x86\crt\src\strftime.c(484) : Assertion failed: FALSE -- assignee: -> haypo nos

[issue13175] packaging uses wrong line endings in RECORD files on Windows

2011-10-15 Thread Vinay Sajip
Vinay Sajip added the comment: I'm trying to reproduce this too, but have failed so far. Which version(s) of Windows did the problems appear on? -- nosy: +vinay.sajip ___ Python tracker __

[issue13182] pysetup run bdist_wininst does not work (tries to use "install" command)

2011-10-15 Thread Vinay Sajip
Vinay Sajip added the comment: Closing as a duplicate of #13151, which also identifies other problems with this command. -- components: +Library (Lib) nosy: +vinay.sajip resolution: -> duplicate status: open -> closed superseder: -> pysetup3 run bdist_wininst fails _

[issue7317] Display full tracebacks when an error occurs asynchronously

2011-10-15 Thread alon horev
alon horev added the comment: Here's the next attempt (took your advice about the convention): Exception ignored in: > Traceback (most recent call last): File "/tmp/bla.py", line 4, in __del__ None.someattr AttributeError: 'NoneType' object has no attribute 'someattr' reminder of the cur

[issue13139] multiprocessing.map skips finally blocks

2011-10-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: As mentioned in http://docs.python.org/dev/library/multiprocessing#multiprocessing.pool.AsyncResult.get “If the remote call raised an exception then that exception will be reraised by get().” map() is just map_async() followed by a get() call on the result. A

[issue13088] Add Py_hexdigits constant: use one unique constant to format a digit to hexadecimal

2011-10-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: You broke compilation under Windows. -- assignee: -> haypo nosy: +pitrou ___ Python tracker ___ __

[issue13186] instance_ass_item() broken in classobject.c (Py2.7)

2011-10-15 Thread Stefan Behnel
New submission from Stefan Behnel : Starting at line 1223 in classobject.c, you can find this code: if (item == NULL) arg = PyInt_FromSsize_t(i); else arg = Py_BuildValue("(nO)", i, item); if (arg == NULL) { Py_DECREF(func); return -1; } res =

[issue7317] Display full tracebacks when an error occurs asynchronously

2011-10-15 Thread Julian
Julian added the comment: The formatting isn't very conventional for Python. Why not use the normal format? i.e. Traceback (most recent call last): File "/tmp/bla.py", line 4, in __del__ None.someattr AttributeError: 'NoneType' object has no attribute 'someattr' Why is this more likely

[issue13185] Why does Python interpreter care about curvy quotes in comments?

2011-10-15 Thread Martin v . Löwis
Martin v. Löwis added the comment: The error message told you exactly what the problem is. Your source file does not conform to PEP 263. The PEP also explains why this applies to comments as well: because the entire file gets decoded according to the source encoding, and parsing (including de

[issue4431] Distutils MSVC doesn't create manifest file

2011-10-15 Thread Martin v . Löwis
Martin v. Löwis added the comment: Corey, Sebastian: VS 2010 is not supported. So failure to work correctly is not a bug in Python. -- ___ Python tracker ___ ___

[issue7317] Display full tracebacks when an error occurs asynchronously

2011-10-15 Thread alon horev
alon horev added the comment: Submitting a patch proposing this format: -BEGIN UNRAISABLE EXCEPTION- Class: AttributeError Instance: "'NoneType' object has no attribute 'someattr'" Function: > Traceback (most recent call last): File "/tmp/bla.py", line 4, in __del__ None.someattr

[issue13153] IDLE crash with unicode bigger than 0xFFFF

2011-10-15 Thread Ned Deily
Ned Deily added the comment: Thanks for the additional investigation. You don't see more in the traceback because the exception is occurring in the _tkinter C glue layer. I am able to reproduce the problem on some other platforms as well (e.g. Python 3.x on OS X with Carbon Tk 8.4). More l