[issue10515] csv sniffer does not recognize quotes at the end of line

2010-11-23 Thread Andrew McNamara
Changes by Andrew McNamara : -- nosy: +andrewmcnamara ___ Python tracker <http://bugs.python.org/issue10515> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue1225769] Proposal to implement comment rows in csv module

2010-02-03 Thread Andrew McNamara
Andrew McNamara added the comment: Note that there is one case that cannot easily be addressed via pre-processing: where the comment character coincidently appears at the start of a line within a multi-line quoted field. For example: # This is a comment 1, 2, "This is field^M #3"

[issue1225769] Proposal to implement comment rows in csv module

2010-02-03 Thread Andrew McNamara
Andrew McNamara added the comment: Okay, while I am sympathetic to the points raised by the people asking for this enhancement, I'm persuaded to reject it by the arguments that the potential benefit is outweighed by the increase in complexity (code and documentation). While the att

[issue416670] MatchObjects not deepcopy()able

2008-11-04 Thread Andrew McNamara
Changes by Andrew McNamara <[EMAIL PROTECTED]>: -- versions: +Python 2.5.3, Python 2.6 ___ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.

[issue416670] MatchObjects not deepcopy()able

2008-11-03 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: One reason why this issue has been having less impact is that a bug in some versions of the copy.py code meant it was ignoring the __deepcopy__ stubs and using the pickle logic to copy _sre objects - so, if you run the right

[issue3756] re.escape() does not work with bytes()

2008-09-10 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: >Looks fine, except I used frozenset for the _alphanum* variables and >reverted to double quotes like the rest of the file. Submitted as r66366. All good. Thankyou. ___ Python tracker <[

[issue3756] re.escape() does not work with bytes()

2008-09-07 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: I meant "I can certainly imagine use cases..." In case it's not clear, I think the implementation in the patch is "good enough" (unless someone can suggest any obvious optimisations). If someone can prove

[issue3756] re.escape() does not work with bytes()

2008-09-07 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: I don't think it's possible to say whether it's preformance critical - I can certainly image use cases such as parser generators where its speed could be noticed. I tried building a version using regular expressio

[issue3756] re.escape() does not work with bytes()

2008-09-04 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: On further testing, sometimes the str version is faster, sometimes the bytes version is faster. Never more than about 50% one way or the other, so probably not worth worrying about, although I still don't really like the imp

[issue3756] re.escape() does not work with bytes()

2008-09-02 Thread Andrew McNamara
Changes by Andrew McNamara <[EMAIL PROTECTED]>: Added file: http://bugs.python.org/file11352/re_escape-patch ___ Python tracker <[EMAIL PROTECTED]> <http://bugs.pytho

[issue3756] re.escape() does not work with bytes()

2008-09-02 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: Will do, although I'm slightly concerned that my "bytes" version of the function is about 50% slower than the "str" version. I can see why, I just can't think of a way to do it any faster. There's

[issue3747] Fix caching in ABCMeta.__subclasscheck__

2008-09-01 Thread Andrew McNamara
Changes by Andrew McNamara <[EMAIL PROTECTED]>: -- nosy: +andrewmcnamara ___ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue3747> ___ _

[issue3756] re.escape() does not work with bytes()

2008-09-01 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: The attached "re_escape.py" is a (somewhat crappy) fix for re.escape() Added file: http://bugs.python.org/file11340/re_escape.py ___ Python tracker <[EMAIL PROTECTED]> <http://

[issue3756] re.escape() does not work with bytes()

2008-09-01 Thread Andrew McNamara
New submission from Andrew McNamara <[EMAIL PROTECTED]>: In python 2, re.escape() works with either str or unicode, but in python 3, re.escape() no longer works correctly with the bytes type. -- components: Regular Expressions messages: 72309 nosy: andrewmcnamara severity:

[issue1225769] Proposal to implement comment rows in csv module

2008-04-15 Thread Andrew McNamara
Andrew McNamara <[EMAIL PROTECTED]> added the comment: I think it's a reasonable enough request - I've certainly had to process CSV files with comments. Iain - appologies for not looking at your request before now - 3 years is a pretty poor response time. Some thoughts: * th

[issue1744580] cvs.get_dialect() return a class object

2007-11-04 Thread Andrew McNamara
Andrew McNamara added the comment: Seems okay to me. I had a quick look at the examples section, and it shows a use like the one I mention, but I wonder if the section on dialects should quote the specific examples I mention? _ Tracker <[EMAIL PROTEC