FW: Unexpexted behaviot of python operators on list

2014-11-25 Thread PANDEY2 Archana (MORPHO)
Hello I hereby would like to share the problem I have found regarding python list implementation:- As per python documentation python list is mutable data object. That problem I found with the list is that is behaves differently when we use '+=' and '+' '=' operators separately. For example-

Dictionary error

2014-11-25 Thread Thuruv V
Please Clarify the 'TypeError: zip argument #1 must support iteration' import openpyxl book = openpyxl.load_workbook('c:/users/c_thv/desktop/tax.xlsx') sheet = book.get_sheet_by_name('Thilip') cell = sheet.cell(row=2,column = 4) i = 2 x = [] y = []while i 10: keys = sheet.cell(row=i,column

Re: Dictionary error

2014-11-25 Thread Steven D'Aprano
Thuruv V wrote: Please Clarify the 'TypeError: zip argument #1 must support iteration' Try it at the interactive interpreter: py zip('abc', [1, 2, 3]) # works fine [('a', 1), ('b', 2), ('c', 3)] But: py zip(1000, [1, 2, 3]) # fails Traceback (most recent call last): File stdin, line 1,

Python Documentation Improvement

2014-11-25 Thread Archana Pandey
Hello I hereby would like to share the problem I have faced regarding python list implementation :- As per python documentation python list is mutable data object. The problem I found with the list is that is behaves differently when we use ‘+=’ and ‘+’ ‘=’ operators separately. For

Re: FW: Unexpexted behaviot of python operators on list

2014-11-25 Thread Steven D'Aprano
PANDEY2 Archana (MORPHO) wrote: Hello I hereby would like to share the problem I have found regarding python list implementation:- As per python documentation python list is mutable data object. That problem I found with the list is that is behaves differently when we use '+=' and '+'

Re: python 2.7 and unicode (one more time)

2014-11-25 Thread Steven D'Aprano
Marko Rauhamaa wrote: Steven D'Aprano steve+comp.lang.pyt...@pearwood.info: Marko Rauhamaa wrote: Py3's byte strings are still strings, though. Hm. I don't think so. In a plain English sense, maybe, but that kind of usage can lead to confusion. Only if you are determined to confuse

Re: FW: Unexpexted behaviot of python operators on list

2014-11-25 Thread Mark Lawrence
On 25/11/2014 11:40, Steven D'Aprano wrote: PANDEY2 Archana (MORPHO) wrote: Hello I hereby would like to share the problem I have found regarding python list implementation:- As per python documentation python list is mutable data object. That problem I found with the list is that is

Re: Python Documentation Improvement

2014-11-25 Thread Mark Lawrence
On 25/11/2014 11:44, Archana Pandey wrote: Hello I hereby would like to share the problem I have faced regarding python list implementation :- As per python documentation python list is mutable data object. The problem I found with the list is that is behaves differently when we use ‘+=’ and

Re: FW: Unexpexted behaviot of python operators on list

2014-11-25 Thread Dave Angel
On 11/25/2014 04:23 AM, PANDEY2 Archana (MORPHO) wrote: Hello Welcome. This is apparently your first post, or at least first for quite a while. Note that this is a text forum (usenet, mailing list), and doesn't properly support either html messages nor attachments. Just tell your

[ANN] PyUBL

2014-11-25 Thread Burak Arslan
All, We've gone through the grunt work of researching and integrating XMLDSIG, XAdES and UBL schemas and its various extensions and dependencies and wrote a bunch of scripts that map these documents to python objects. UBL stands for Universal Business Language. It's an OASIS standard that

Re: Most gratuitous comments

2014-11-25 Thread Marco Buttu
On 21/11/2014 07:52, Marko Rauhamaa wrote: sohcahto...@gmail.com: My point was that I was making fun of CS professors that demand a comment on every line of code, regardless of how clear the line of code is. Unfortunately, a lot of software houses do a similar thing. Not quite every line, but

Re: Most gratuitous comments

2014-11-25 Thread Marko Rauhamaa
Marco Buttu marco.bu...@gmail.com: To acknowledge the OP, the statistics module deserves to be taken as example for writing good comments and docstrings: https://hg.python.org/cpython/file/3.4/Lib/statistics.py True, it is done with good style. It concentrates on documenting use and lets the

Re: python 2.7 and unicode (one more time)

2014-11-25 Thread Chris Angelico
On Tue, Nov 25, 2014 at 10:56 PM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: I think this conversation is going nowhere, so it's probably best to end it. \0 ChrisA -- https://mail.python.org/mailman/listinfo/python-list

Re: FW: Unexpexted behaviot of python operators on list

2014-11-25 Thread Denis McMahon
On Tue, 25 Nov 2014 12:20:26 +, Mark Lawrence wrote: a=[1,2,3] binds a to the list [1,2,3] b=a binds b to a b+=[4,5] Changes existing b, which is also a x=[1,2,3] binds x to the list [1,2,3] y=x binds y to x y=y+[4,5] Binds y to a new list which comprises previous y plus

Re: PYTHON LOGGING with StreamHandler and FileHandler

2014-11-25 Thread Ganesh Pal
Thanks for the hint , I was able to get the error messages on the console by setting the StreamHandler level to WARNING . It works for me know butone LAST question , it might sound simple, but Iam not able to understand the difference between - (a) ch.setLevel(logging.WARNING) and

Re: Python Signal/Slot + QThred code analysis

2014-11-25 Thread Juan Christian
On Mon Nov 24 2014 at 11:56:31 PM Michael Torrie torr...@gmail.com wrote: Looks alright. Does it work? Well, no =/ First I had to remove the multiple inheritance, because Qt doesn't allow that, so I removed the QObject. Second, just for testing I'm calling the module directly using: timer =

Re: Basic asyncio usage

2014-11-25 Thread Benjamin Risher
On Monday, November 24, 2014 10:26:42 AM UTC-6, Marko Rauhamaa wrote: Benjamin Risher brisher...@gmail.com: I was wondering if you ever made progress with your asyncio project. I'm currently digging around for examples and reference material and came across your post. I'd be

Re: Most gratuitous comments

2014-11-25 Thread Steven D'Aprano
Marko Rauhamaa wrote: Marco Buttu marco.bu...@gmail.com: To acknowledge the OP, the statistics module deserves to be taken as example for writing good comments and docstrings: https://hg.python.org/cpython/file/3.4/Lib/statistics.py True, it is done with good style. It concentrates on

Re: Python Documentation Improvement

2014-11-25 Thread Steven D'Aprano
Archana Pandey wrote: [...] A = a + 1 and a += 1 both behave in same way for all data types except python Lists I cannot think of any other mutable data type that supports + but there are mutable data types that support other augmented assignment operators: py a = set(abcd) py b = a # now

Re: PYTHON LOGGING with StreamHandler and FileHandler

2014-11-25 Thread Peter Otten
Ganesh Pal wrote: Thanks for the hint , I was able to get the error messages on the console by setting the StreamHandler level to WARNING . It works for me know butone LAST question , it might sound simple, but Iam not able to understand the difference between - (a)

Re: Python Signal/Slot + QThred code analysis

2014-11-25 Thread MRAB
On 2014-11-25 13:58, Juan Christian wrote: On Mon Nov 24 2014 at 11:56:31 PM Michael Torrie torr...@gmail.com mailto:torr...@gmail.com wrote: Looks alright. Does it work? Well, no =/ First I had to remove the multiple inheritance, because Qt doesn't allow that, so I removed the QObject.

Fwd: Python Signal/Slot + QThred code analysis

2014-11-25 Thread Juan Christian
On Tue Nov 25 2014 at 1:42:24 PM MRAB pyt...@mrabarnett.plus.com wrote: I think that the problem there is that strings don't have an __exit__ method. I don't understand what you said, what you mean by that? =/ -- https://mail.python.org/mailman/listinfo/python-list

Call for notes about Eric IDE

2014-11-25 Thread Pietro Moras
In view of next edition of the Eric IDE Technical Report (forecast: 3rd quarter '15) we'll welcome your testimony of experiences and use of specific Eric IDE's features, such as: – Special features of your choice, such as: SQL Browser, Qt Forms Designer, Debug Remote Configurable, Eric

Re: Dictionary error

2014-11-25 Thread John Gordon
In mailman.16275.1416914234.18130.python-l...@python.org Thuruv V wasp52...@gmail.com writes: Please Clarify the 'TypeError: zip argument #1 must support iteration' import openpyxl book = openpyxl.load_workbook('c:/users/c_thv/desktop/tax.xlsx') sheet = book.get_sheet_by_name('Thilip')

Re: Dictionary error

2014-11-25 Thread Dave Angel
On 11/25/2014 04:34 AM, Thuruv V wrote: Please Clarify the 'TypeError: zip argument #1 must support iteration' import openpyxl book = openpyxl.load_workbook('c:/users/c_thv/desktop/tax.xlsx') sheet = book.get_sheet_by_name('Thilip') cell = sheet.cell(row=2,column = 4) i = 2 x = [] y = []while

Re: Fwd: Python Signal/Slot + QThred code analysis

2014-11-25 Thread MRAB
On 2014-11-25 15:48, Juan Christian wrote: On Tue Nov 25 2014 at 1:42:24 PM MRAB pyt...@mrabarnett.plus.com mailto:pyt...@mrabarnett.plus.com wrote: I think that the problem there is that strings don't have an __exit__ method. I don't understand what you said, what you mean by that? =/ The

Re: Challenge: optimizing isqrt

2014-11-25 Thread Serhiy Storchaka
п'ятниця, 21-лис-2014 08:15:57 ви написали: This looks very good indeed. As a matter of interest, is there any particular reason you have used 2*b instead of b+b? Might b+b be faster than b*2? Yes, it is slightly faster, but the effect is indiscernible in total time. But there is not harm to

CFFI distribution questions

2014-11-25 Thread Israel Brewster
So I have a python module that I have written which uses CFFI to link against a C library I have compiled. Specifically, it is a Database driver for the 4th dimension database, using an open-source C library distributed by the 4D company. I have tested the module and C code on a couple of

PyPI auth issues (Server response (401): basic auth failed)

2014-11-25 Thread Ricardo Bánffy
Hi folks. I must be doing something wrong, but I (and the clever folks at the #python channel) can't figure what. I'm doing a: python setup.py register -r pypitest And getting the following in return running register running egg_info writing Appengine_Fixture_Loader.egg-info/PKG-INFO writing

Re: Fwd: Python Signal/Slot + QThred code analysis

2014-11-25 Thread Juan Christian
So guys, I had to change to approach, I read that using Qt I can't do multiple inheritance. So my Outpost class can't be like 'Outpost(QObject, QThred)'. I had to change the code a bit: from PySide.QtCore import QObject, QThread, Signal import requests import bs4 class Worker(QThread): def

Quotation Ugliness

2014-11-25 Thread Tim Daneliuk
A problem for your consideration: We are given a tuple of delimiter string pairs to quote or comment text, possibly over multiple lines. Something like this: delims = (('', ''), (', '), ('#', '\n'), (\*, *\), ('\\', '\n') ...) These may be nested. Here's the problem: Determine is the

Re: Quotation Ugliness

2014-11-25 Thread Tim Chase
On 2014-11-25 18:18, Tim Daneliuk wrote: A problem for your consideration: We are given a tuple of delimiter string pairs to quote or comment text, possibly over multiple lines. Something like this: delims = (('', ''), (', '), ('#', '\n'), (\*, *\), ('\\', '\n') ...) These may

Re: Quotation Ugliness

2014-11-25 Thread Chris Angelico
On Wed, Nov 26, 2014 at 11:18 AM, Tim Daneliuk tun...@tundraware.com wrote: A problem for your consideration: We are given a tuple of delimiter string pairs to quote or comment text, possibly over multiple lines. Something like this: delims = (('', ''), (', '), ('#', '\n'), (\*, *\),

Re: Challenge: optimizing isqrt

2014-11-25 Thread Dave Angel
On 11/25/2014 02:31 PM, Serhiy Storchaka wrote: п'ятниця, 21-лис-2014 08:15:57 ви написали: This looks very good indeed. As a matter of interest, is there any particular reason you have used 2*b instead of b+b? Might b+b be faster than b*2? Yes, it is slightly faster, but the effect is

Content-Type (was: Fwd: Python Signal/Slot + QThred code analysis)

2014-11-25 Thread Christoph M. Becker
Juan Christian wrote: OFF-TOPIC: You guys said that my emails had some trash HTML and strange stuffs, is it OK now? You're still sending: Content-Type: multipart/alternative Please configure your MUA to send Content-Type: text/plain only. -- Christoph M. Becker --

Re: Quotation Ugliness

2014-11-25 Thread Tim Daneliuk
On 11/25/2014 06:44 PM, Chris Angelico wrote: You may have issues with your definition of nesting, though. For instance, what's it mean if you have double-quotes, then a hash? It means that the hash is quoted as part of the literal string. then the only nesting you need worry about is /* and

Re: Quotation Ugliness

2014-11-25 Thread Tim Daneliuk
On 11/25/2014 06:40 PM, Tim Chase wrote: On 2014-11-25 18:18, Tim Daneliuk wrote: A problem for your consideration: We are given a tuple of delimiter string pairs to quote or comment text, possibly over multiple lines. Something like this: delims = (('', ''), (', '), ('#', '\n'), (\*,

Re: Quotation Ugliness

2014-11-25 Thread Chris Angelico
On Wed, Nov 26, 2014 at 12:18 PM, Tim Daneliuk tun...@tundraware.com wrote: And what should happen with mismatched quotes? do(th/*is, and, th*/at) Match pairs as usual, and let the remaining unterminated quote run on. Wait, what? Where's an unterminated quote? I can imagine two ways of

Re: Quotation Ugliness

2014-11-25 Thread Tim Chase
On 2014-11-25 19:20, Tim Daneliuk wrote: hen you find any opener, you seek its corresponding closer, and then special-case /* to count any additional /* and look for a */ for each one */ . That's more or less where I was headed. I just wanted something less brute force :) This seems to

Re: Quotation Ugliness

2014-11-25 Thread Ben Finney
Tim Daneliuk tun...@tundraware.com writes: Here's the problem: Determine is the string S appears *outside* or *inside* any such quotation. This is a problem for parsing text. There is no general, simple solution. If someone tries to convince you they have one, be highly suspicious: it will

Re: Fwd: Python Signal/Slot + QThred code analysis

2014-11-25 Thread Michael Torrie
On 11/25/2014 02:36 PM, Juan Christian wrote: So guys, I had to change to approach, I read that using Qt I can't do multiple inheritance. So my Outpost class can't be like 'Outpost(QObject, QThred)'. I had to change the code a bit: snip So, let's see the problems: Traceback (most recent

Re: Quotation Ugliness

2014-11-25 Thread Tim Daneliuk
On 11/25/2014 07:32 PM, Chris Angelico wrote: On Wed, Nov 26, 2014 at 12:18 PM, Tim Daneliuk tun...@tundraware.com wrote: And what should happen with mismatched quotes? do(th/*is, and, th*/at) Match pairs as usual, and let the remaining unterminated quote run on. Wait, what? Where's

Re: Quotation Ugliness

2014-11-25 Thread Tim Daneliuk
On 11/25/2014 07:44 PM, Tim Chase wrote: On 2014-11-25 19:20, Tim Daneliuk wrote: hen you find any opener, you seek its corresponding closer, and then special-case /* to count any additional /* and look for a */ for each one */ . That's more or less where I was headed. I just wanted

Re: Quotation Ugliness

2014-11-25 Thread Tim Daneliuk
On 11/25/2014 07:54 PM, Ben Finney wrote: Tim Daneliuk tun...@tundraware.com writes: Here's the problem: Determine is the string S appears *outside* or *inside* any such quotation. This is a problem for parsing text. There is no general, simple solution. If someone tries to convince you

Re: [ANN] PyUBL

2014-11-25 Thread dieter
Burak Arslan burak.ars...@arskom.com.tr writes: We've gone through the grunt work of researching and integrating XMLDSIG, XAdES and UBL schemas and its various extensions and dependencies and wrote a bunch of scripts that map these documents to python objects. In this context, I would like to

Using a password with ‘sudo’ (was: Quotation Ugliness)

2014-11-25 Thread Ben Finney
Tim Daneliuk tun...@tundraware.com writes: Here's a usecase - I want to know whether I need to use a sudo password when the user passes a command on the command line of a program: […] In the first instance, I need the sudo passoword, in the second I don't. I don't understand what “need a

Re: PyPI auth issues (Server response (401): basic auth failed)

2014-11-25 Thread dieter
Ricardo Bánffy rban...@gmail.com writes: I must be doing something wrong, but I (and the clever folks at the #python channel) can't figure what. ... Registering Appengine-Fixture-Loader to http://pypi.python.org/pypi Server response (401): basic auth failed So, what am I doing wrong? I

Re: Quotation Ugliness

2014-11-25 Thread Chris Angelico
On Wed, Nov 26, 2014 at 5:04 PM, Tim Daneliuk tun...@tundraware.com wrote: Here's a usecase - I want to know whether I need to use a sudo password when the user passes a command on the command line of a program: someprog.py uname sudo cat /etc/sudoers vs. someprog.py uname echo sudo cat

[issue22581] Other mentions of the buffer protocol

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Could anyone please look at the patch? I touches only docs and comments. -- keywords: +needs review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22581

[issue22581] Other mentions of the buffer protocol

2014-11-25 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- Removed message: http://bugs.python.org/msg231643 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22581 ___

[issue22581] Other mentions of the buffer protocol

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Could anyone please look at the patch? It touches only docs and comments. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22581 ___

[issue20899] Nested namespace imports do not work inside zip archives

2014-11-25 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: +serhiy.storchaka versions: +Python 3.5 -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20899 ___

[issue20002] Cleanup and microoptimize pathlib

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If you are not interested in any of proposed changes Antoine, this issue can be closed. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20002 ___

[issue20002] Cleanup and microoptimize pathlib

2014-11-25 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20002 ___ ___

[issue20002] Cleanup and microoptimize pathlib

2014-11-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: Not really, sorry. -- status: pending - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20002 ___ ___

[issue19676] Add the namereplace error handler

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ping. -- assignee: - serhiy.storchaka keywords: +needs review versions: +Python 3.5 -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19676 ___

[issue22798] time.mktime doesn't update time.tzname

2014-11-25 Thread Akira Li
Akira Li added the comment: One of the ways to fix this issue is to synchronize time.tzname attribute with the corresponding C tzname variable. I've uploaded sync-time-timezone-attr-with-c.diff patch that synchronizes tzname, timezone, altzone, daylight attributes. The patch also includes

[issue22798] time.mktime doesn't update time.tzname

2014-11-25 Thread Akira Li
Changes by Akira Li 4kir4...@gmail.com: Removed file: http://bugs.python.org/file37132/test_mktime_changes_tzname.c ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22798 ___

[issue19676] Add the namereplace error handler

2014-11-25 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: The patch looks good to me. But it seems that the reverse operation is not possible in the general case: .decode('unicode_escape') assumes a latin-1 or ascii encoding. Should we document this? -- nosy: +amaury.forgeotdarc

[issue19676] Add the namereplace error handler

2014-11-25 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: The patch looks good. One nit: the name buffer length should be NAME_MAXLEN instead of 100. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19676 ___

[issue22939] integer overflow in iterator object

2014-11-25 Thread Clement Rouault
New submission from Clement Rouault: I found an interger overflow in the standard iterator object (Objects/iterobject.c) The `it_index` attribute used by the iterator is a `Py_ssize_t` but overflow is never checked. So after the index `PY_SSIZE_T_MAX`, the iterator object will ask for the

[issue19676] Add the namereplace error handler

2014-11-25 Thread Nick Coghlan
Nick Coghlan added the comment: Patch looks good to me, too. As far as Amaury's question goes, isn't the general reverse operation the same as for the existing backslashreplace handler? That is, decode with the appropriate ASCII compatible encoding (since ASCII compatibility is needed for

[issue20002] Cleanup and microoptimize pathlib

2014-11-25 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- resolution: - rejected stage: patch review - resolved ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20002 ___

[issue19676] Add the namereplace error handler

2014-11-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset 32d08aacffe0 by Serhiy Storchaka in branch 'default': Issue #19676: Added the namereplace error handler. https://hg.python.org/cpython/rev/32d08aacffe0 -- nosy: +python-dev ___ Python tracker

[issue19676] Add the namereplace error handler

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you all for reviews. One nit: the name buffer length should be NAME_MAXLEN instead of 100. NAME_MAXLEN is private name available only in Modules/unicodedata.c. Making it public name would be other issue. I have increased buffer size to 256.

[issue22286] Allow backslashreplace error handler to be used on input

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Synchronized with the tip (resolved conflicts with issue22470 and issue19676). -- assignee: - serhiy.storchaka keywords: +needs review Added file: http://bugs.python.org/file37274/backslashreplace_decode_2.patch

[issue19105] pprint doesn't use all width

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Could anyone please make a review? -- keywords: +needs review versions: +Python 3.5 -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19105 ___

[issue18965] 2to3 can produce illegal bytes literals

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Now Python 2 with the -3 option warns about b-prefixed strings with non-ASCII characters (issue19656). -- versions: +Python 3.5 -Python 3.3 ___ Python tracker rep...@bugs.python.org

[issue22939] integer overflow in iterator object

2014-11-25 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: +rhettinger, serhiy.storchaka stage: - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22939 ___

[issue22638] ssl module: the SSLv3 protocol is vulnerable (POODLE attack)

2014-11-25 Thread Robert Kuska
Robert Kuska added the comment: FYI fedora (rawhide) has SSLv3 disabled in SSLv23 method of openssl package. http://pkgs.fedoraproject.org/cgit/openssl.git/commit/?id=80b5477597e9f0d9fababd854adfb4988b37efd5 This looks like the same approach as in attached issue22638.diff. -- nosy:

[issue22939] integer overflow in iterator object

2014-11-25 Thread R. David Murray
R. David Murray added the comment: For possibly relevant background information, see issue 21444 and the issues linked from it, and issue 14794. -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22939

[issue22939] integer overflow in iterator object

2014-11-25 Thread STINNER Victor
STINNER Victor added the comment: The `it_index` attribute used by the iterator is a `Py_ssize_t` but overflow is never checked. Yes it is a bug. iter_iternext() must raises an OverflowError if it-it_index is equal to PY_SSIZE_T_MAX. -- nosy: +haypo

[issue22940] readline does not offer partial saves

2014-11-25 Thread bru
New submission from bru: The readline module offers write_history_file from readline/history.h write_history, but there's no append_history_file that would invoke append_history from the C header. This causes inconveniences when saving history to a file (like shown there:

[issue22841] Avoid to use coroutine with add_signal_handler()

2014-11-25 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@gmail.com: -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22841 ___

[issue22685] memory leak: no transport for pipes by create_subprocess_exec/shell

2014-11-25 Thread STINNER Victor
STINNER Victor added the comment: Here is a patch with a simple unit test. Can someone review it? If not, I will commit it without review. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22685

[issue20899] Nested namespace imports do not work inside zip archives

2014-11-25 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- nosy: +gregory.p.smith, twouters ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20899 ___ ___

[issue22581] Other mentions of the buffer protocol

2014-11-25 Thread R. David Murray
R. David Murray added the comment: There's no review link. And no obvious reason why there isn't. Could you try regenerating the patch and uploading it again? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22581

[issue22939] integer overflow in iterator object

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think OverflowError is good for maintained releases, but for 3.5 Clement's idea with long index looks attractive to me. In any case an exception should be raised for negative argument in __setstate__(). Let split this issue on two parts. First fix the bug

[issue22581] Other mentions of the buffer protocol

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Regenerated for review. I don't know why Rietweld didn't like previous patch. -- Added file: http://bugs.python.org/file37276/bytes_like.patch ___ Python tracker rep...@bugs.python.org

[issue22685] memory leak: no transport for pipes by create_subprocess_exec/shell

2014-11-25 Thread Guido van Rossum
Guido van Rossum added the comment: Sorry, looks good. On Tue, Nov 25, 2014 at 6:37 AM, STINNER Victor rep...@bugs.python.org wrote: STINNER Victor added the comment: Here is a patch with a simple unit test. Can someone review it? If not, I will commit it without review. --

[issue22685] memory leak: no transport for pipes by create_subprocess_exec/shell

2014-11-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset f75d40c02f0a by Victor Stinner in branch '3.4': Closes #22685, asyncio: Set the transport of stdout and stderr StreamReader https://hg.python.org/cpython/rev/f75d40c02f0a New changeset 7da2288183d1 by Victor Stinner in branch 'default': (Merge 3.4)

[issue22685] memory leak: no transport for pipes by create_subprocess_exec/shell

2014-11-25 Thread STINNER Victor
STINNER Victor added the comment: Fix also pushed to Python 3.4, 3.5 and to Tulip. Thanks for the report wabu. Tulip commit: changeset: 1350:c3a9d355eb34 user:Victor Stinner victor.stin...@gmail.com date:Tue Nov 25 17:17:13 2014 +0100 files: asyncio/subprocess.py

[issue22941] IPv4Interface arithmetic changes subnet mask

2014-11-25 Thread Søren Løvborg
New submission from Søren Løvborg: Addition and subtraction of integers are documented for ipaddress.IPv4Address and ipaddress.IPv6Address, but also work for IPv4Interface and IPv6Interface (though the only documentation of this is a brief mention that the Interface classes inherit from the

[issue22939] integer overflow in iterator object

2014-11-25 Thread STINNER Victor
STINNER Victor added the comment: I think OverflowError is good for maintained releases, but for 3.5 Clement's idea with long index looks attractive to me. What is your use case? -- ___ Python tracker rep...@bugs.python.org

[issue22941] IPv4Interface arithmetic changes subnet mask

2014-11-25 Thread Søren Løvborg
Søren Løvborg added the comment: Proposed implementation patch attached. If this has any interest, I'll look into expanding the patch to include documentation and unit tests. Resulting behavior: import ipaddress ipaddress.IPv4Interface('10.0.0.1/8') + 1 IPv4Interface('10.0.0.2/8')

[issue19676] Add the namereplace error handler

2014-11-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset b6fab008d63a by Berker Peksag in branch 'default': Issue #19676: Tweak documentation a bit. https://hg.python.org/cpython/rev/b6fab008d63a -- ___ Python tracker rep...@bugs.python.org

[issue22941] IPv4Interface arithmetic changes subnet mask

2014-11-25 Thread Berker Peksag
Changes by Berker Peksag berker.pek...@gmail.com: -- nosy: +ncoghlan, pmoody ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22941 ___ ___

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2014-11-25 Thread Miki Tebeka
Miki Tebeka added the comment: Can we also update iglob [1] as well? [1] https://docs.python.org/2/library/glob.html#glob.iglob -- nosy: +tebeka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22524

[issue20204] pydocs fails for some C implemented classes

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The problem not in pydoc or inspect itself. In Python 3.3 _tkinter.TkappType has the __module__ attribute: import _tkinter _tkinter.TkappType.__module__ 'builtins' Something was changed in 3.4 and builtin classes without dot in qualified name no longer

[issue22906] PEP 479: Change StopIteration handling inside generators

2014-11-25 Thread Chris Angelico
Chris Angelico added the comment: Known issues with the current patch, if anyone feels like playing with this who better knows the code: 1) Needs a __future__ directive to control behaviour 2) test_generators needs to be heavily reworked 3) The test of what exception was thrown needs to also

[issue22939] integer overflow in iterator object

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is your use case? Something like range(). I agree that it is very unlike to encounter this problem in real work, and we can live with implementation-related limitation (for which OverflowError exists). --

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2014-11-25 Thread Akira Li
Akira Li added the comment: scandir is slower on my machine: $ git clone https://github.com/benhoyt/scandir $ cd scandir/ $ ../cpython/python benchmark.py /usr/ Using slower ctypes version of scandir Comparing against builtin version of os.walk() Priming the system's cache...

[issue22685] memory leak: no transport for pipes by create_subprocess_exec/shell

2014-11-25 Thread wabu
wabu added the comment: thanks for the fixes 'n' integration -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22685 ___ ___ Python-bugs-list

[issue22518] integer overflow in encoding unicode

2014-11-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do you want to add a bigmem test or close this issue Benjamin? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22518 ___

[issue22942] Language Reference - optional comma

2014-11-25 Thread Jordan
New submission from Jordan: # I would like to report three bugs in the # Language Reference Python 3.4.2 # # bug 1: Typo in parameter_list # # # In 8.6 the rule for parameter_list should be corrected: The first | should be ( #

[issue22942] Language Reference - optional comma

2014-11-25 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22942 ___ ___

[issue22518] integer overflow in encoding unicode

2014-11-25 Thread Benjamin Peterson
Benjamin Peterson added the comment: I wouldn't object if you had a patch. -- nosy: +benjamin.peterson ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22518 ___

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2014-11-25 Thread STINNER Victor
STINNER Victor added the comment: scandir is slower on my machine: Please share more information about your config: OS, disk type (hard drive, SSD, something else), filesystem, etc. -- ___ Python tracker rep...@bugs.python.org

[issue22898] segfault during shutdown attempting to log ResourceWarning

2014-11-25 Thread Xavier de Gaye
Xavier de Gaye added the comment: The attached script raises the PyExc_RecursionErrorInst singleton and reproduces the issue. The attached patch fixes the issue by ignoring the warning when clearing PyExc_RecursionErrorInst and clearing the frames associated with its traceback, in

[issue22898] segfault during shutdown attempting to log ResourceWarning

2014-11-25 Thread Xavier de Gaye
Changes by Xavier de Gaye xdeg...@gmail.com: Added file: http://bugs.python.org/file37279/warn_2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22898 ___

  1   2   >