[issue1158] %f format for datetime objects

2007-09-12 Thread Brett Cannon
Brett Cannon added the comment: Are you going to add support to strptime as well? As for the 'time' module, I don't think it would be useful as it serves no purpose since the time tuple can't resolve to that resolution. If you do add support, though, I guess you just default to 0. -- n

[issue1777530] ctypes on Solaris

2007-09-12 Thread Aki
Aki added the comment: Sorry for not having done this earlier. I thought this was already closed ... I used your updated patch and installed the Python 2.5.1 from scratch. It worked without any problem except python-config issue, which I have reported in another case [issue1095]. __

[issue1158] %f format for datetime objects

2007-09-12 Thread Skip Montanaro
New submission from Skip Montanaro: Attached is a patch for py3k which adds a %f format code to its strftime method. When included in a format string it expands to the number of microseconds in the object. date, time and datetime objects all support the format (though I'm not sure what, if anyt

[issue1772851] Decimal and long hash, compatibly and efficiently

2007-09-12 Thread ajaksu
ajaksu added the comment: Thanks a lot for the explanation. I still think it could be valuable (C?)py3k change (but now for the predictability, as you say :) Regarding the performance of Decimal.__hash__: I believe (int) hash performance would be a moot issue if Decimal.__int__ was (much) fas

[issue1686386] Python SEGFAULT on tuple.__repr__ and str()

2007-09-12 Thread Brett Cannon
Changes by Brett Cannon: -- title: Python SEGFAULT on invalid superclass access -> Python SEGFAULT on tuple.__repr__ and str() _ Tracker <[EMAIL PROTECTED]> _ _

[issue1686386] Python SEGFAULT on invalid superclass access

2007-09-12 Thread Brett Cannon
Brett Cannon added the comment: OK, so I have attached a possible patch. I found out that tuple.__repr__ didn't do anything to prevent infinite recursion since you can't pull it off from Python code. But obviously C code is another matter. =) Same goes for object.__str__; it didn't think abou

[issue1157] test_urllib2net fails on test_ftp

2007-09-12 Thread Guido van Rossum
New submission from Guido van Rossum: == ERROR: test_ftp (__main__.OtherNetworkTests) -- Traceback (most recent call last): File "Lib/test/test_urllib2net.py",

[issue1772851] Decimal and long hash, compatibly and efficiently

2007-09-12 Thread Mark Dickinson
Mark Dickinson added the comment: To help explain what's going on, here's some Python code. The Python function long_hash1 below has the properties that: (1) long_hash1(n) == hash(n) for almost all integers n, with a very

[issue1686386] Python SEGFAULT on invalid superclass access

2007-09-12 Thread Brett Cannon
Changes by Brett Cannon: -- versions: +Python 2.6 _ Tracker <[EMAIL PROTECTED]> _ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue1686386] Python SEGFAULT on invalid superclass access

2007-09-12 Thread Brett Cannon
Brett Cannon added the comment: So the first example (in msg31624) crashes because of infinite recursion with the repr of exceptions:: #7771 0x00065178 in BaseException_repr (self=0x5dc6b8) at Objects/exceptions.c:128 #7772 0x0001d90c in PyObject_Repr (v=0x5dc6b8) at Objects/object.c:362 #7773 0

[issue1145] Allow str.join to join non-string types (as per PEP 3100)

2007-09-12 Thread Guido van Rossum
Guido van Rossum added the comment: There's one additional issue. If any of the items is a bytes, the call should fail. __ Tracker <[EMAIL PROTECTED]> __ __

[issue1038] [py3k] pdb does not work in python 3000

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Fixed in rev. 58127. -- assignee: -> georg.brandl nosy: +georg.brandl resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]> __ __

[issue1148] TypeError on join - httplib mixing str and bytes

2007-09-12 Thread Guido van Rossum
Guido van Rossum added the comment: Committed revision 58126. -- resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]> __

[issue1151] "TypeError: expected string, bytes found" instead of KeyboardInterrupt

2007-09-12 Thread Guido van Rossum
Guido van Rossum added the comment: Confirmed. Weird. -- nosy: +gvanrossum __ Tracker <[EMAIL PROTECTED]> __ ___ Python-bugs-list mailing list

[issue1019] Cleanup pass on _curses and _curses_panel

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Unfortunately, the patch is hard to review with all the whitespace cleanup distracting from semantic changes. Can you produce a patch with only those changes? -- nosy: +georg.brandl __ Tracker <[EMAIL PROTECTED]>

[issue1148] TypeError on join - httplib mixing str and bytes

2007-09-12 Thread Guido van Rossum
Guido van Rossum added the comment: Confirmed. I'll fix it ASAP. -- assignee: -> gvanrossum nosy: +gvanrossum __ Tracker <[EMAIL PROTECTED]> __ __

[issue1686386] Python SEGFAULT on invalid superclass access

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Brett, you recently fixed an infinite recursion crasher, right? -- assignee: -> brett.cannon nosy: +brett.cannon _ Tracker <[EMAIL PROTECTED]> _

[issue1098] decode_unicode doesn't nul-terminate

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: The function in question is in Python/ast.c. Martin, does the string need to be null-terminated or does DecodeUnicodeEscape need to be fixed (since it takes an explicit length argument)? -- assignee: -> loewis nosy: +georg.brandl, loewis type: -> crash

[issue1120] "make altinstall" installs pydoc, idle, smtpd.py with broken shebang lines

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Fixed in rev. 58125, should be merged to 3k shortly. Thanks! -- nosy: +georg.brandl resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]>

[issue1777530] ctypes on Solaris

2007-09-12 Thread Thomas Heller
Thomas Heller added the comment: Can someone please test the patch and report back? -- Thanks _ Tracker <[EMAIL PROTECTED]> _ ___ Python-bugs

[issue1145] Allow str.join to join non-string types (as per PEP 3100)

2007-09-12 Thread Guido van Rossum
Guido van Rossum added the comment: I like this, but the patch has problems: you don't error-check the return value from PyObject_Unicode() or PyUnicode_FromObject() (and why do you need the latter call anyway?) Also in the docstring I would reference str() instead of __str__(). There are also

[issue1207379] class property fset not working

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: It says "... for new-style classes (classes that derive from object)." I think this is clear enough. -- resolution: -> wont fix status: open -> closed _ Tracker <[EMAIL PROTECTED]>

[issue1121] Document inspect.getfullargspec()

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Documented in rev. 1121. -- resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]> __ ___ P

[issue1153] help(pickle) fails: unorderable types: type() < type()

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Fixed in the repr module (it was calling sorted() on sets and dicts, which is wrong without fallback) in rev. 58122 (trunk), 58123 (2.5) -- will be merged to 3.0 shortly. -- assignee: -> georg.brandl nosy: +georg.brandl resolution: -> fixed status: open

[issue1156] Suggested change to _exit function description in os module documentation

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Assigning to Martin. -- assignee: -> loewis nosy: +georg.brandl, loewis __ Tracker <[EMAIL PROTECTED]> __ ___ P

[issue1739468] Add a -z interpreter flag to execute a zip file

2007-09-12 Thread Guido van Rossum
Guido van Rossum added the comment: PJE's patch looks good to me too. Stylistic nits: - The proper name of the now-public null importer type ought to be PyNullImporter_Type, to rhyme with e.g. PyString_Type - There's a multi-line if that has the closing parenthesis in an odd place at the start

[issue1154] Carbon.CF memory leak

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Fixed in rev. 58119, 58120 (2.5). -- nosy: +georg.brandl resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]> __

[issue1156] Suggested change to _exit function description in os module documentation

2007-09-12 Thread Johann Tonsing
New submission from Johann Tonsing: The document from which http://docs.python.org/lib/os-process.html was generated contains: "Note: The standard way to exit is sys.exit(n). _exit() should normally only be used in the child process after a fork()." Should "child" be replaced with "parent"?

[issue1598083] Top-level exception handler writes to stdout unsafely

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: I'll look into it. -- nosy: +georg.brandl _ Tracker <[EMAIL PROTECTED]> _ ___ Python-bugs-list mailin

[issue1139] PyFile_Encoding should be PyFile_SetEncoding

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Fixed in rev. 58117, 58118 (2.5). Thanks! -- resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]> __

[issue1122] PyTuple_Size and PyTuple_GET_SIZE return type documentation incorrect

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Fixed in rev. 58115, 58116 (2.5). Thanks! -- resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]> __

[issue1152] Bug in documentation for SimpleXMLRPCServer

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Fixed in rev. 58114. -- resolution: -> fixed status: open -> closed __ Tracker <[EMAIL PROTECTED]> __ ___ Pytho

[issue1136] Bdb documentation

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Okay, committed as rev. 58112, 58113. Thank you! -- resolution: -> accepted status: open -> closed __ Tracker <[EMAIL PROTECTED]> __ __

[issue1535659] NNTPS support in nntplib

2007-09-12 Thread Bill Janssen
Bill Janssen added the comment: Georg got it right -- this patch is bogus. I'm going to close it as "won't fix". Feel free to re-open it as an RFE with a good patch. -- resolution: -> wont fix status: open -> closed _ Tracker <[EMAIL PROTECTED]> <

[issue1155] Carbon.CF memory management problem

2007-09-12 Thread hhas
New submission from hhas: While other CF...RefObj_Convert functions return a borrowed object, CFStringRefObj_Convert will return either a new or borrowed CFStringRef depending on the type of value supplied (str, unicode or CFString). As a result, extensions that use CFStringRefObj_Convert func

[issue1772851] Decimal and long hash, compatibly and efficiently

2007-09-12 Thread ajaksu
ajaksu added the comment: IMHO this patch should be considered for (at least) py3k, in which long becomes the new int. As there is current interest in long/int performance[1] this seems like a good time to raise this kind of issue. Mark, could you please outline the semantic changes (specially

[issue1136] Bdb documentation

2007-09-12 Thread Cristina Yenyxe González García
Cristina Yenyxe González García added the comment: Oops, of course a filename should be in canonical form (an absolute name which does not contain repeated path separators or symbolic links)! __ Tracker <[EMAIL PROTECTED]> __

[issue1154] Carbon.CF memory leak

2007-09-12 Thread hhas
New submission from hhas: CFStringRefObj_Convert leaks memory when passed a str. See attached diff file for patch. -- components: Macintosh files: CFmodule.diff messages: 55843 nosy: hhas severity: normal status: open title: Carbon.CF memory leak type: resource usage versions: Python 2.

[issue1136] Bdb documentation

2007-09-12 Thread Georg Brandl
Georg Brandl added the comment: Thanks for reviewing, I'll finish and commit that one shortly. -- assignee: -> georg.brandl nosy: +georg.brandl __ Tracker <[EMAIL PROTECTED]> __ _

[issue1142] code sample showing errors reading large files with py 2.5/3.0

2007-09-12 Thread Guido van Rossum
Guido van Rossum added the comment: Cool. This helps track down the bug a bit more; it's either in (our routine) getline_via_fgets or it's in Microsoft's text mode line end translation (which universal newlines bypasses). I'm assigning this to Tim Peters, who probably still has a Windows box and

[issue1136] Bdb documentation

2007-09-12 Thread Tim Golden
Tim Golden added the comment: I've reviewed the docs for English and general readability. As mentioned, I've no idea of the tech involved. I did look through the bdb.py source and the existing docs for pdb to get some idea of the terminology used. Ultimately I've changed very little; in a couple

[issue1153] help(pickle) fails: unorderable types: type() < type()

2007-09-12 Thread Marcin 'Qrczak' Kowalczyk
New submission from Marcin 'Qrczak' Kowalczyk: Python 3.0a1 (py3k, Sep 8 2007, 15:57:56) [GCC 4.2.1 20070719 (release) (PLD-Linux)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import pickle >>> help(pickle) Traceback (most recent call last): File "", l