[issue10047] python-2.6.6 coredump running newspipe

2010-12-01 Thread Thomas Klausner
Thomas Klausner added the comment: I've updated the operating system to a 5.99.39, and the problem disappeared. Strange. Thanks for the suggestions. -- status: open -> closed ___ Python tracker __

[issue9299] os.makedirs(): Add a keyword argument to suppress "File exists" exception

2010-12-01 Thread Terry J. Reedy
Terry J. Reedy added the comment: I removed trailing '\' and whitespace, refreshed against current repository, removing conflicts, and committed. r86930 -- assignee: georg.brandl -> terry.reedy resolution: accepted -> fixed status: open -> closed __

[issue10482] subprocess and deadlock avoidance

2010-12-01 Thread Glenn Linderman
Glenn Linderman added the comment: Sorry, left some extraneous code in the last message, here is the right code: def _writerthread(self, fhr, fhw, length=None): if length is None: flag = True while flag: buf = fhr.read( 512 ) f

[issue10482] subprocess and deadlock avoidance

2010-12-01 Thread Glenn Linderman
Glenn Linderman added the comment: Here's an updated _writerthread idea that handles more cases: def _writerthread(self, fhr, fhw, length=None): if length is None: flag = True while flag: buf = fhr.read( 512 ) fhw.write( buf )

[issue10600] surrogateescape'd paths not readable on Windows XP.

2010-12-01 Thread Martin v . Löwis
Martin v. Löwis added the comment: This is not a bug. You can't expect that using an arbitrary codec (such as UTF-8) with the surrogateescape code, and expect to be able that opening the file will be able to produce the correct filename. This won't work on Unix, in the general case, either. T

[issue10600] surrogateescape'd paths not readable on Windows XP.

2010-12-01 Thread Campbell Barton
Campbell Barton added the comment: This bug is with blender3d, were the paths are stored internally in C as simple char arrays - bytes. We could expose all path names as bytes too through our C/python API, this would at least be a 1:1 mapping, however Id prefer using strings if possible. Sin

[issue10602] csv test_register_kwargs has invalid message parameters

2010-12-01 Thread Alex Earl
New submission from Alex Earl : in test_csv.py, the follow test is declared. def test_register_kwargs(self): name = 'fedcba' csv.register_dialect(name, delimiter=';') try: self.assertTrue(csv.get_dialect(name).delimiter, '\t') self.assertTrue(list(csv.reader('X;Y;Z',

[issue9573] importing a module that executes fork() raises RuntimeError

2010-12-01 Thread Nick Coghlan
Nick Coghlan added the comment: Fixed for 3.2 in r86928. The fix has not been backported to 3.1, since it depends on the fix for issue 7242 (r78527) which was itself never backported to 3.1 after being forward ported to the py3k branch as part of a bulk merge (r83318) Backporting to 2.7 woul

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: Glaring at my mistakes. > There was wrong examples in the test_urllib2 which I just corrected. There were.. > Expect for the difference in (it = iter(data) - Which I am seeking Except for ... -- ___ Python track

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Xuanji Li added the comment: thought of a better way, we can check if data is true; this will cover "" and b"". this is in issue_3243_py3k_7.patch -- Added file: http://bugs.python.org/file19902/issue_3243_py3k_7.patch ___ Python tracker

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: On Thu, Dec 02, 2010 at 03:20:05AM +, Xuanji Li wrote: > Actually I don't think you can go around changing test_urllib2.py, > they are after all regression tests... and surely some users will > send "" as data. > Think about it this way. In py3k, socket.s

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: On Thu, Dec 02, 2010 at 03:16:53AM +, Xuanji Li wrote: > And my version too... > +if hasattr(data, '__len__') and not len(data): +request.add_unredirected_header('Content-length', '0') This is very special case. It sho

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Xuanji Li added the comment: Actually I don't think you can go around changing test_urllib2.py, they are after all regression tests... and surely some users will send "" as data. My patch handles the case of 0-length data specially, removing the need for 2) Can call len but not buffer: assume

[issue10464] netrc module not parsing passwords containing #s.

2010-12-01 Thread R. David Murray
R. David Murray added the comment: Committed to py3k in r86925, 3.1 in r86926, and 2.7 in r86927. Thanks for the patch, Xuanji. -- nosy: +r.david.murray resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Pyth

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Xuanji Li added the comment: And my version too... -- Added file: http://bugs.python.org/file19901/issue_3243_py3k_6.patch ___ Python tracker ___

Re: [issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
On Thu, Dec 02, 2010 at 03:08:55AM +, Xuanji Li wrote: > > req = Request("http://example.com/";, "") That should be: > req = Request("http://example.com/";, b"") I updated some of those in the latest updated patch. ___ Python-bugs-list mailing li

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: Updated patch after correcting the mistake (bytes vs str) in the previous one. -- Added file: http://bugs.python.org/file19900/Issue3243-6.patch ___ Python tracker ___

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Xuanji Li added the comment: > > 2) Can call len but not buffer: assume len == #bytes > Why do you need it at all? Hmm, I'm looking at the the tests in urllib2 that fail if we omit this... in test_urllib2 there are tests that do this: req = Request("http://example.com/";, "") and they expec

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: On Thu, Dec 02, 2010 at 02:19:10AM +, Senthil Kumaran wrote: > On Wed, Dec 01, 2010 at 10:06:25AM +, Antoine Pitrou wrote: > > +try: > > + self.sock.sendall(data) > > > > Indentation problem here. > > I could notice it now. Shall fix

[issue9611] FileIO not 64-bit safe under Windows

2010-12-01 Thread STINNER Victor
Changes by STINNER Victor : Removed file: http://bugs.python.org/file19898/read_write_32bits.patch ___ Python tracker ___ ___ Python-bugs-list

[issue9611] FileIO not 64-bit safe under Windows

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: (oops, the patch contained unrelated changes: remove trailing spaces) -- Added file: http://bugs.python.org/file19899/read_write_32bits.patch ___ Python tracker ___

[issue9611] FileIO not 64-bit safe under Windows

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: I agree that clamping is a nice solution, and attached patch implements it. About the question of the loop: FileIO.readall() uses while(1) without checking for signals. It looks like new_buffersize() maximum size is not BIGCHUNK but (BIGCHUNK-1)*2: /

Re: [issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
On Wed, Dec 01, 2010 at 05:08:26PM +, Antoine Pitrou wrote: > Antoine Pitrou added the comment: > > if not request.has_header('Content-length'): > > if (not hasattr(data, '__read__') and > > What is __read__ supposed to be? I don't think is required. The previous 2.x version patch was d

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: On Wed, Dec 01, 2010 at 02:56:56PM +, Xuanji Li wrote: > orsenthil: Hi, i don't quite understand why iter() needs to be > called explicitly on data? As I understand it, if data is an > iterable then you can use a for loop on it directly. > The reasoning I

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: On Wed, Dec 01, 2010 at 10:06:25AM +, Antoine Pitrou wrote: > +try: > + self.sock.sendall(data) > > Indentation problem here. I could notice it now. Shall fix it. > > +if isinstance(data,str): > +con

[issue8863] Display Python backtrace on SIGSEGV, SIGFPE and fatal error

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: > If it's an env variable, though, it should be clear that it's > CPython-specific, so I'm not sure how to call it. Why do you think that only this variable is CPython-specific? CPython has an option called PYTHONDONTWRITEBYTECODE, but PyPy doesn't create .pyc

[issue10417] unittest triggers UnicodeEncodeError with non-ASCII character in the docstring of the test function

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: See also #10601: "sys.displayhook: use backslashreplace error handler if repr(value) is not encodable to sys.stdout". -- ___ Python tracker __

[issue10600] surrogateescape'd paths not readable on Windows XP.

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: Use surrogateescape error handler to decode a Windows path is not a good idea. On Windows, the problem is not to decode a path (ANSI => wide char), but to encode a path (wide char => ANSI) to use a function expecting bytes path encoded to the ANSI code page.

[issue10601] sys.displayhook: use backslashreplace error handler if repr(value) is not encodable to sys.stdout

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: > This issue is opposed to the PEP 3128: > > << Default error-handler of sys.stdout should be 'backslashreplace' Oops sorry, no it is not opposed to the PEP (this issue doesn't propose to change the default error handler of sys.stdout). -- __

[issue9198] Should repr() print unicode characters outside the BMP?

2010-12-01 Thread STINNER Victor
Changes by STINNER Victor : -- resolution: -> invalid status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue10601] sys.displayhook: use backslashreplace error handler if repr(value) is not encodable to sys.stdout

2010-12-01 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +amaury.forgeotdarc, lemburg ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe

[issue9198] Should repr() print unicode characters outside the BMP?

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: I created a new issue for Ezio's proposition to patch sys.displayhook: issue #10601. To answer the initial question, "Should repr() print unicode characters outside the BMP?", Marc-Andre, Ezio and me agree that we should keep the current behavior for non-BMP

[issue10601] sys.displayhook: use backslashreplace error handler if repr(value) is not encodable to sys.stdout

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: This issue is opposed to the PEP 3128: << Default error-handler of sys.stdout should be 'backslashreplace'. Stuff written to stdout might be consumed by another program that might misinterpret the escapes. For interactive session, it is possible to make 'bac

[issue10601] sys.displayhook: use backslashreplace error handler if repr(value) is not encodable to sys.stdout

2010-12-01 Thread STINNER Victor
New submission from STINNER Victor : On Windows, the Python interpreter fails to display a result if stdout encoding is unable to encode it. This problem exists since Python 3.0. Eg. see issue #1602. This problem is not specific to Windows. Even if stdout encoding is UTF-8 (which is the defau

[issue2380] Raise a Py3K warning for catching nested tuples with non-BaseException exceptions

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: issue2380.diff does not apply anymore. -- assignee: -> belopolsky stage: -> needs patch ___ Python tracker ___ _

[issue10580] Installer sentence in bold

2010-12-01 Thread R. David Murray
R. David Murray added the comment: I think Boštjan is correct that that sentence is not parallel to the others. If I understand correctly, at that point the installation is complete, and it is the final 'exit or back' dialog. So I think the title should be "Complete Python x.x.x Installatio

[issue9915] speeding up sorting with a key

2010-12-01 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: > Just wanted to post this so there weren't any illusions about the > patch being a big win. > When a key function is defined, this is all you can possibly shave > off the time for a comparison. I don't want to argue whether the patch is a big win or not (I

[issue9915] speeding up sorting with a key

2010-12-01 Thread Raymond Hettinger
Raymond Hettinger added the comment: Just for the record, I wanted to highlight how little room there is for optimization here. The sort wrapper is *very* thin: sortwrapper_richcompare(sortwrapperobject *a, sortwrapperobject *b, int op) { if (!PyObject_TypeCheck(b, &PySortWrapper_Type)) {

[issue4335] inspect.getsourcelines ignores last line in module

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: 3.2 and 2.7 don't exhibit this issue. I added a test in r86922. -- nosy: -BreamoreBoy resolution: -> out of date stage: patch review -> committed/rejected status: open -> closed ___ Python tracker

[issue9915] speeding up sorting with a key

2010-12-01 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: > The use of Py_LOCAL_INLINE is new to me since we usually use #define > instead, but this has a cleaner look to it. I am unclear on whether > all the our target compilers support an inline keyword. If you're > sure it works everywhere, that's great. I fi

[issue6135] subprocess seems to use local 8-bit encoding and gives no choice

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: > ... it always seems to use the local 8-bit encoding The locale encoding is not necessary a 8-bit encoding, it can by a multibyte like... UTF-8 :-) -- subprocess.patch: You should maybe use io.open(process.stdout.fileno(), encoding=..., errors=...) instead

[issue10600] surrogateescape'd paths not readable on Windows XP.

2010-12-01 Thread Campbell Barton
Campbell Barton added the comment: note, this bug was reported to me by a user running windows 7, 64bits. -- ___ Python tracker ___ _

[issue10600] surrogateescape'd paths not readable on Windows XP.

2010-12-01 Thread Campbell Barton
New submission from Campbell Barton : Attached is a script which works in linux but not windows XP 32bit with Python 3.1.3. The problem is that the path can be written to when specified as bytes but when escaped it fails. -- components: IO files: utf8_surrogateescape.py messages: 1230

[issue9915] speeding up sorting with a key

2010-12-01 Thread Raymond Hettinger
Raymond Hettinger added the comment: Thanks. This nice, clean diff is much more reviewable and it looks like what I expected. The use of Py_LOCAL_INLINE is new to me since we usually use #define instead, but this has a cleaner look to it. I am unclear on whether all the our target comp

[issue6135] subprocess seems to use local 8-bit encoding and gives no choice

2010-12-01 Thread STINNER Victor
STINNER Victor added the comment: About the topic: > subprocess seems to use local 8-bit encoding and gives no choice I don't understand that: by default, Python 2 and Python 3 use byte strings, so there is no encoding (nor error handler). I don't see how you can get unicode from a process onl

[issue10092] calendar does not restore locale properly

2010-12-01 Thread R. David Murray
R. David Murray added the comment: Boštjan, please see issue 10466 for further information about your question on fr_FR vs French. Windows, as usual, does not follow the standards. -- ___ Python tracker

[issue10092] calendar does not restore locale properly

2010-12-01 Thread Stephen Hansen
Stephen Hansen added the comment: On windows, "France" may work and "fr_FR" may not; yet on OSX its exactly the opposite. Its not consistant across platforms. -- ___ Python tracker ___

[issue10599] sgmllib.parse_endtag() is not respecting quoted text

2010-12-01 Thread Michael Brooks
Michael Brooks added the comment: Oops, I had a misnomer in my bug report. http://bug>link"> is not escaped and there for the href should be parsed in this condition but not parsed in the attached sgmllib_bug.py. -- ___ Python tracker

[issue10092] calendar does not restore locale properly

2010-12-01 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- nosy: -belopolsky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue10599] sgmllib.parse_endtag() is not respecting quoted text

2010-12-01 Thread Michael Brooks
New submission from Michael Brooks : In the attached example is a very simple usage of sgmllib that is trying to parse: http://bug>link"> The bug is that sgmllib is parsing this href. Browsers on the other hand see this as the input's value. Also keep in mind that escaping of quote marks i

[issue10092] calendar does not restore locale properly

2010-12-01 Thread Boštjan Mejak
Boštjan Mejak added the comment: Yes, I know this issue is closed but I wonder how could your Python interpreter not error on >>> calendar.LocaleTextCalendar(locale='fr_FR').formatmonthname(2010,10,10) Please retry executing the above line of code in Python 2.7.1 interpreter and tell me if you

[issue10092] calendar does not restore locale properly

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Boštjan, Please don't add comments to closed issues. If you believe there is a remaining issue, please file a new report. Issue numbers are in good supply! This issue was fixed in r85728. It is best when this information is the last message on a clo

[issue10092] calendar does not restore locale properly

2010-12-01 Thread Boštjan Mejak
Boštjan Mejak added the comment: >>> calendar.LocaleTextCalendar(locale='fr_FR').formatmonthname(2010,10,10) is not valid because 'fr_FR' is not a valid value for the 'locale' argument What is valid is this: >>> calendar.LocaleTextCalendar(locale='French').formatmonthname(2010,10,10) -

[issue10092] calendar does not restore locale properly

2010-12-01 Thread Boštjan Mejak
Changes by Boštjan Mejak : Removed file: http://bugs.python.org/file19316/unnamed ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue10092] calendar does not restore locale properly

2010-12-01 Thread Boštjan Mejak
Changes by Boštjan Mejak : Removed file: http://bugs.python.org/file19306/unnamed ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

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

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: I don't see anything "easy" in this issue. Error handling in exception or signal handlers is quite tricky. I don't see this as a high priority either, but will leave this for others to decide. -- keywords: -easy nosy: +belopolsky ___

[issue4113] Add custom __repr__ to functools.partial

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Let me close this issue before any serious bikeshedding begins. We can always reconsider when users complain that eval(repr(x)) does not work for their partial objects. -- status: open -> closed ___ Python t

[issue4113] Add custom __repr__ to functools.partial

2010-12-01 Thread Éric Araujo
Éric Araujo added the comment: I think the main purpose of repr is debugging, so I’d favor the unambiguous form (with the id) to the nice-looking one (module.name). -- ___ Python tracker __

[issue4113] Add custom __repr__ to functools.partial

2010-12-01 Thread Terry J. Reedy
Terry J. Reedy added the comment: I would prefer the module.name without the repr decoration. -- status: pending -> open ___ Python tracker ___ __

[issue9915] speeding up sorting with a key

2010-12-01 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: Antoine and Raymond, thank you for the valuable feedback. Attached is a revised version of the patch, which restricts changes to those directly related to moving elements in the keys and values arrays at the same time. I apologize for having gotten a littl

[issue10598] curses fails to import on Solaris

2010-12-01 Thread River Tarnell
New submission from River Tarnell : On Solaris 10 using system libcurses, curses fails to import: hemlock% python3.1 Python 3.1.3 (r313:86834, Dec 1 2010, 19:51:26) [GCC 4.5.1] on sunos5 Type "help", "copyright", "credits" or "license" for more information. >>> import curses Traceback (most re

[issue4113] Add custom __repr__ to functools.partial

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: I simplified the partial_repr() code in issue4113b.diff and committed as r86916. I wonder, however, if for the common case of func being a named function, displaying func.__name__ or func.__module__ + '.' + func.__name__ in repr(partial) may be more apr

[issue7662] time.utcoffset()

2010-12-01 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo versions: +Python 3.3 -Python 2.7, Python 3.2 ___ Python tracker ___ ___ Python-bugs-lis

[issue9527] Add aware local time support to datetime module

2010-12-01 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pytho

[issue766910] fix one or two bugs in trace.py

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Eli, Would you like to review this patch? -- nosy: +eli.bendersky -BreamoreBoy ___ Python tracker ___ _

[issue766910] fix one or two bugs in trace.py

2010-12-01 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : Removed file: http://bugs.python.org/file18960/unnamed ___ Python tracker ___ ___ Python-bugs-list mailing

[issue766910] fix one or two bugs in trace.py

2010-12-01 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : Removed file: http://bugs.python.org/file18959/unnamed ___ Python tracker ___ ___ Python-bugs-list mailing

[issue8902] add datetime.time.now() for consistency

2010-12-01 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- resolution: -> postponed versions: +Python 3.3 -Python 3.2 ___ Python tracker ___ ___ Python-bugs

[issue5476] datetime: timedelta(minutes = i) silently fails with numpy.int32 input

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Travis, feel free to close this without further action or use the information here to open a numpy issue. -- assignee: belopolsky -> teoliphant status: open -> pending ___ Python tracker

[issue9528] Add pure Python implementation of time module to CPython

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: BDFL and python-dev were opposed to this idea. -- resolution: -> rejected stage: -> committed/rejected status: open -> closed ___ Python tracker ___

[issue9268] Document annotation option to pickletools.dis

2010-12-01 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- resolution: fixed -> stage: committed/rejected -> needs patch title: Add annotation option to pickletools.dis -> Document annotation option to pickletools.dis ___ Python tracker

[issue5516] equality not symmetric for subclasses of datetime.date and datetime.datetime

2010-12-01 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- resolution: -> postponed versions: +Python 3.3 -Python 3.2 ___ Python tracker ___ ___ Python-bugs

[issue887237] Machine integers

2010-12-01 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: As far as I understand, the main concern about issue887237.diff was code duplication. There are two ways to fight it: C preprocessor tricks as in issue887237-macro.diff and code generation as done in numpy. With improved macro support in many compiler

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: > if not request.has_header('Content-length'): > if (not hasattr(data, '__read__') and What is __read__ supposed to be? > 2) Can call len but not buffer: assume len == #bytes Why do you need it at all? -- ___

[issue10589] I/O ABC docs should specify which methods have implementations

2010-12-01 Thread Daniel Urban
Changes by Daniel Urban : -- nosy: +durban ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue8743] set() operators don't work with collections.Set instances

2010-12-01 Thread Daniel Urban
Changes by Daniel Urban : -- nosy: +durban ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.or

[issue10597] Py_SetPythonHome document shows same url twice.

2010-12-01 Thread INADA Naoki
New submission from INADA Naoki : http://docs.python.org/c-api/init.html#Py_SetPythonHome > The libraries are searched in home/lib/pythonversion and > home/lib/pythonversion. Is the second "{home}/lib/python{version}" wrong? -- assignee: d...@python components: Documentation messages:

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Changes by Xuanji Li : Removed file: http://bugs.python.org/file19892/issue_3243_py3k_5.patch ___ Python tracker ___ ___ Python-bugs-list maili

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Xuanji Li added the comment: attaching new patch. this implements the memoryview solution suggested by pitrou. but it does contain this thing: if not request.has_header('Content-length'): if (not hasattr(data, '__read__') and isinstance(data, collections.Iterable)): print(

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Xuanji Li added the comment: attaching new patch. this implements the memoryview solution suggested by pitrou. but it does contain this thing: if not request.has_header('Content-length'): if (not hasattr(data, '__read__') and isinstance(data, collections.Iterable)): print(

[issue10594] Typo in PyList_New doc.

2010-12-01 Thread Georg Brandl
Georg Brandl added the comment: Thanks, fixed in r86914. -- nosy: +georg.brandl resolution: accepted -> fixed status: open -> closed ___ Python tracker ___ _

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Xuanji Li
Xuanji Li added the comment: orsenthil: Hi, i don't quite understand why iter() needs to be called explicitly on data? As I understand it, if data is an iterable then you can use a for loop on it directly. -- ___ Python tracker

[issue10596] modulo operator bug

2010-12-01 Thread Mark Dickinson
Mark Dickinson added the comment: Did you look at the second footnote on that page? -- ___ Python tracker ___ ___ Python-bugs-list ma

[issue7359] mailbox cannot modify mailboxes in system mail spool

2010-12-01 Thread Ole Laursen
Ole Laursen added the comment: Just got bitten by this too. Renaming is good and all, but as far as I can tell, it will never work with the system spool. It's not just that you can't create a temporary file in the directory, you can't rename files into it either. If I create an empty file so

[issue10596] modulo operator bug

2010-12-01 Thread Сергей Хлутчин
Сергей Хлутчин added the comment: >From the documetation: The modulo operator always yields a result with the same sign as its second operand (or zero); the absolute value of the result is strictly smaller than the absolute value of the second operand. --

[issue10596] modulo operator bug

2010-12-01 Thread Mark Dickinson
Mark Dickinson added the comment: What results were you expecting here? Both those results look fine to me (though it's arguable that the second should be +0.0 rather than -0.0). -- assignee: -> mark.dickinson ___ Python tracker

[issue10596] modulo operator bug

2010-12-01 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +mark.dickinson ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue10596] modulo operator bug

2010-12-01 Thread Сергей Хлутчин
New submission from Сергей Хлутчин : Result of the modulo operator is wrong: >>> (-2.22044604925e-16)%4 4.0 >>> (-4.0)%4 -0.0 -- messages: 122991 nosy: Sergio.Ĥlutĉin priority: normal severity: normal status: open title: modulo operator bug type: behavior versions: Python 2.6 _

[issue10595] Adding a syslog.conf reader in syslog

2010-12-01 Thread Tarek Ziadé
New submission from Tarek Ziadé : The syslog module allows to configure via openlog() the facility. There's one missing feature though, I'd love to have in a new API: a way to read the syslog configuration, and in particular to know where each facility file is located on the system. e.g.:

[issue8805] urllib should support SSL contexts

2010-12-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: HTTPSHandler now allows to pass an SSLContext and the old API should be buried in the ground, closing. -- resolution: -> rejected status: open -> closed ___ Python tracker __

[issue10594] Typo in PyList_New doc.

2010-12-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: You don't need to backport, we'll do it ourselves. Can someone from the doc team please review/commit? -- assignee: eli.bendersky -> d...@python nosy: +pitrou stage: -> patch review ___ Python tracker

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: Senthil: +try: + self.sock.sendall(data) Indentation problem here. +if isinstance(data,str): +content_length = len(data) I'm not sure I understand. What does sending an unicode string mean? +# Ch

[issue10084] SSL support for asyncore

2010-12-01 Thread Dirkjan Ochtman
Changes by Dirkjan Ochtman : -- nosy: +djc ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue3243] Support iterable bodies in httplib

2010-12-01 Thread Senthil Kumaran
Senthil Kumaran added the comment: Give a try to this minor variation of the patch with tests added and let me know your review comments. -- Added file: http://bugs.python.org/file19890/Issue3243-4.patch ___ Python tracker

[issue10592] pprint module doesn't work well with OrderedDicts

2010-12-01 Thread Éric Araujo
Changes by Éric Araujo : -- superseder: general pprint rewrite -> ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib