execnet-1.0.9: small refinements

2010-11-26 Thread holger krekel
Hi all, just released execnet-1.0.9, the rapid multi-Python deployment library. 1.0. contains some small additions and refinements, mostly implemented by Ronny Pfannschmidt. See the docs fore more info: http://codespeak.net/execnet cheers, holger 1.0.9 -

pytest-2.0: asserts++, unittest++, reporting++, config++, docs++

2010-11-26 Thread holger krekel
py.test 2.0.0: asserts++, unittest++, reporting++, config++, docs++ === Welcome to pytest-2.0.0, a major new release of py.test, the rapid easy Python testing tool. There are many new features and enhancements, see below for

tox-0.9: better CI bootstrapping / custom PyPI index servers

2010-11-26 Thread holger krekel
Hi all, i just released tox-0.9, the generic virtualenv-using test integration automation tool (tm). This release brings a new zero-install way to deploy tox and your test suite on Hudson slaves. Apart from one or more Python interpreters you do not need anything on the slave side, see here

PyUseCase 3.4.1: Python GUI test tool

2010-11-26 Thread Geoff Bache
Hi all, 3.4.1 is mostly bugfixes related to PyGTK, although some internal reorganisation and minor API changes are also included. Also proof of concept support for Hildon extension to PyGTK, the GUI used on Nokia's Maemo phones and restored support for Python 2.5 which was dropped in 3.4 and then

berkeley db in concurrent environment

2010-11-26 Thread XieTian
Hi list, I'm using bsddb.dbshelve in a conservative and concurrent environment (python version 2.4). I'm wondering if the dbshelve class methods are atomic. That is, if one process keeps writing data to one database file and another process keeps reading from it, will the reading process get

Re: Newbie subprocess question

2010-11-26 Thread News123
On 11/26/2010 12:18 AM, Tim Harig wrote: On 2010-11-25, Hugo Léveillé hu...@fastmail.net wrote: I'm starting various application using subprocess.Popen without any problem. The problem is with application inside Program Files. It looks like subprocess is stopping the application string after

Re: Scheme as a virtual machine?

2010-11-26 Thread Benjamin L. Russell
namekuseijin namekusei...@gmail.com writes: I have to say I'm always amazed how ad hominens can generate quite strong responses to the point of making a lot of new faces (or mail accounts) suddenly appear... ;) Actually, I had just noticed that aspect as well. Is it just me, or does anybody

Re: Scheme as a virtual machine?

2010-11-26 Thread Benjamin L. Russell
dekudekup...@yahoo.com (Benjamin L. Russell) writes: When I was a student at my college, one of the students once told me a secret about how a computer program ran by a professor for a course in introduction to systems programming checked to ensure that the students who were submitting

Re: Parsing markup.

2010-11-26 Thread Jon Clements
On Nov 26, 4:03 am, MRAB pyt...@mrabarnett.plus.com wrote: On 26/11/2010 03:28, Joe Goldthwaite wrote:   I’m attempting to parse some basic tagged markup.  The output of the   TinyMCE editor returns a string that looks something like this;     pThis is a paragraph with bbold/b and iitalic/i

How to parse a text block?

2010-11-26 Thread Sergey Smirnov
Hi all. I have a lot of text blocks that looks like this one *** Layer 3 Message type: CP-Data Device: MS1 Time: 19:57:44.71 CP-User data length : 37 RPDU Message type indicator (MTI) : (1) RP-DATA The question is how to parse given text block into a dictionary that looks like the

Re: SQLite date fields

2010-11-26 Thread Duncan Booth
Tim Roberts t...@probo.com wrote: However, when it comes to writing-back data to the table, SQLite is very forgiving and is quite happy to store '25/06/2003' in a date field, SQLite is essentially typeless. ALL fields are stored as strings, with no interpretation. You can store whatever

passing a tuple into a class function as a single argument

2010-11-26 Thread greyw...@gmail.com
Hi everyone, The following program doesn't work as expected: #Python 2.7 wxPython 2.9 import wx class MyFrame(wx.Frame): We simply derive a new class of Frame. def __init__(self, parent, title): wx.Frame.__init__(self, parent, title=title, size=(200,100))

Re: passing a tuple into a class function as a single argument

2010-11-26 Thread Mel
greyw...@gmail.com wrote: Hi everyone, The following program doesn't work as expected: #Python 2.7 wxPython 2.9 import wx class MyFrame(wx.Frame): We simply derive a new class of Frame. def __init__(self, parent, title): wx.Frame.__init__(self, parent,

Re: what a cheap rule

2010-11-26 Thread Fuzzyman
On Nov 26, 1:10 am, Steven D'Aprano steve +comp.lang.pyt...@pearwood.info wrote: On Thu, 25 Nov 2010 08:15:21 -0800, Yingjie Lan wrote: Intuition #1: as if you raise an exception type, and then match that type. It seems that no instances are involved here (Intuitively). Your intuition

Re: Needed: Real-world examples for Python's Cooperative Multiple Inheritance

2010-11-26 Thread Michele Simionato
On Nov 24, 9:08 pm, Raymond Hettinger pyt...@rcn.com wrote: So far, the only situation I can find where method names necessarily overlap is for the basics like __init__(), close(), flush(), and save() where multiple parents need to have their own initialization and finalization. I do not

Re: Help with suds: HTTP Error 401

2010-11-26 Thread Oskar
I was having the same issue until I updated suds to the newest version. -- http://mail.python.org/mailman/listinfo/python-list

Re: SQLite date fields

2010-11-26 Thread Tim Chase
On 11/26/2010 07:20 AM, Duncan Booth wrote: Tim Robertst...@probo.com wrote: SQLite is essentially typeless. ALL fields are stored as strings, with no interpretation. You can store whatever you want in any column. The column types are basically there to remind YOU how to handle the data.

ANN: Leo 4.8 final

2010-11-26 Thread Edward K. Ream
Leo 4.8 final is now available at: http://sourceforge.net/project/showfiles.php?group_id=3458package_id=29106 Leo is a text editor, data organizer, project manager and much more. See: http://webpages.charter.net/edreamleo/intro.html The highlights of Leo 4.8: -- - Leo

Re: PyQt Installation Problem on Windows

2010-11-26 Thread Hans-Peter Jansen
On Wednesday 24 November 2010, 23:03:14 Saul Spatz wrote: Hi, I've been trying to install PyQt on Windows XP Pro so that I can try out eric ide. I used the binary windows installer for PyQt. I can run eric as administrator, but not with my ordinary user account. By running eric.bat with

Re: playful coding problems for 10 year olds

2010-11-26 Thread Aahz
In article mailman.459.1288643471.2218.python-l...@python.org, Daniel Fetchinson fetchin...@googlemail.com wrote: My niece is interested in programming and python looks like a good choice (she already wrote a couple of lines :)) She is 10 and I thought it would be good to have a bunch of playful

Kind of plugin system

2010-11-26 Thread Gaëtan Podevijn
Hello, Here is my problem. I need to get some informations from files stored on my filesystem, Flickr and Picasa. So the idea is to create a class (for instance, InformationsProvider) that provides common methods for those three sources, then, for each source, I create a class that inherits from

Dictionaries inside out

2010-11-26 Thread Greg Lindstrom
I am working on a project where I'm using dictionaries to hold the translations to codes (i.e., {'1':'Cheddar','2':'Ice Hockey','IL':'Thermostat Broken'}). The bulk of the application requires me to translate codes to their meaning, but it would be nice to be able to translate a meaning back to

Re: Dictionaries inside out

2010-11-26 Thread Burton Samograd
Greg Lindstrom gslindst...@gmail.com writes: I am working on a project where I'm using dictionaries to hold the translations to codes (i.e., {'1':'Cheddar','2':'Ice Hockey','IL':'Thermostat Broken'}).  The bulk of the application requires me to translate codes to their meaning, but it would

Re: inverse of a matrix with Fraction entries

2010-11-26 Thread casevh
On Nov 25, 1:28 pm, Daniel Fetchinson fetchin...@googlemail.com wrote: Okay, I see your point and I completely agree. Surely it will be faster to do it with integers, will give it a shot. Cheers, Daniel -- Psss, psss, put it down! -http://www.cafepress.com/putitdown You may want to look

Re: Dictionaries inside out

2010-11-26 Thread Gaëtan Podevijn
Found in Dive in Python 3 : a_dict = {'a': 1, 'b': 2, 'c': 3} {value:key for key, value in a_dict.items()} {1: 'a', 2: 'b', 3: 'c'} 2010/11/26 Burton Samograd bur...@userful.com Greg Lindstrom gslindst...@gmail.com writes: I am working on a project where I'm using dictionaries to hold

Re: a regexp riddle: re.search(r'(?:(\w+), |and (\w+))+', 'whatever a, bbb, and c') =? ('a', 'bbb', 'c')

2010-11-26 Thread Aahz
In article ad755502-bf79-46ea-b7ee-57ac6f7ee...@z26g2000prf.googlegroups.com, Phlip phlip2...@gmail.com wrote: Thanks all for playing! And as usual I forgot a critical detail: I'm writing a matcher for a Morelia /viridis/ Scenario step, so the matcher must be a single regexp. Why? (You're

Re: Needed: Real-world examples for Python's Cooperative Multiple Inheritance

2010-11-26 Thread John Nagle
On 11/25/2010 5:36 PM, Raymond Hettinger wrote: On Nov 25, 3:38 pm, John Naglena...@animats.com wrote: Best practice for this is don't do it. Some name clashes ought to simply be detected as errors, rather than being given such complex semantics. That may well be true. If a coder has

Re: inverse of a matrix with Fraction entries

2010-11-26 Thread John Nagle
On 11/24/2010 10:30 AM, Robert Kern wrote: On 11/24/10 12:07 PM, Daniel Fetchinson wrote: The whole story is that I have a matrix A and matrix B both of which have rational entries and they both have pretty crazy entries too. Their magnitude spans many orders of magnitude, but inverse(A)*B is

Re: Matlab equivalent syntax in Python

2010-11-26 Thread Akand Islam
On Nov 26, 12:37 am, Tim Roberts t...@probo.com wrote: Akand Islam sohel...@gmail.com wrote: Can anyone please suggest me what will be the good way to use matlab equivalent of profile clear, profile on, profile off, profile resume and profile viewer in Python? Python has a number of ways of

Re: Dictionaries inside out

2010-11-26 Thread Terry Reedy
On 11/26/2010 1:13 PM, Greg Lindstrom wrote: I am working on a project where I'm using dictionaries to hold the translations to codes (i.e., {'1':'Cheddar','2':'Ice Hockey','IL':'Thermostat Broken'}). The bulk of the application requires me to translate codes to their meaning, but it would be

Re: Matlab equivalent syntax in Python

2010-11-26 Thread Cameron Simpson
On 26Nov2010 13:15, Akand Islam sohel...@gmail.com wrote: | Thanks for your posting. Like, here is the following Matlab codes | which I am trying to transform into Python. Here you | will find profile clear, profile on, profile off, profile resume, | profile viewer, and drawnow syntaxes. So, what

Re: inverse of a matrix with Fraction entries

2010-11-26 Thread Steven D'Aprano
On Fri, 26 Nov 2010 12:54:12 -0800, John Nagle wrote: For ordinary number crunching, rational arithmetic is completely inappropriate. Why? -- Steven -- http://mail.python.org/mailman/listinfo/python-list

Re: Dictionaries inside out

2010-11-26 Thread Ben Finney
(Replying to Greg, though his original message doesn't appear at Gmane.) Greg Lindstrom gslindst...@gmail.com writes: I am working on a project where I'm using dictionaries to hold the translations to codes (i.e., {'1':'Cheddar','2':'Ice Hockey','IL':'Thermostat Broken'}).  The bulk of

Symposium “Computational Methods in Image Analysis ” within the USNCCM 11 Congress – Announce Call for Pa pers

2010-11-26 Thread tava...@fe.up.pt
Dear Colleague, Within the 11th U.S. National Congress on Computational Mechanics (USNCCM 11 - www.usnccm.org), to be held in Minnesota, USA, in July 25-29, 2011, we are organizing the Symposium “Computational methods in image analysis”. Examples of some topics that will be considered in the

Re: Dictionaries inside out

2010-11-26 Thread Ben Finney
Ben Finney ben+pyt...@benfinney.id.au writes: code_by_desc = dict( (desc, code) for (code, desc) in codes_to_messages.items()) Bah, I fumbled an edit. Try this:: code_by_desc = dict( (desc, code) for (code, desc) in desc_by_code.items()) -- \“The reason we

Re: Matlab equivalent syntax in Python

2010-11-26 Thread Akand Islam
On Nov 26, 3:50 pm, Cameron Simpson c...@zip.com.au wrote: On 26Nov2010 13:15, Akand Islam sohel...@gmail.com wrote: | Thanks for your posting. Like, here is the following Matlab codes | which I am trying to transform into Python. Here you | will find profile clear, profile on, profile off,

Re: Needed: Real-world examples for Python's Cooperative Multiple Inheritance

2010-11-26 Thread Mark Wooding
John Nagle na...@animats.com writes: I'd argue that a better implementation would require that when there's a name clash, you have to specify the class containing the name. In other words, if A is a subclass of B, then B.foo() overrides A.foo(). But if C is a subclass of A and B, and there's

Re: SQLite date fields

2010-11-26 Thread Alan Harris-Reid
To all those who have replied on this thread - many thanks. It looks as though I've got to look further into date objects, SQLite's native date functions, detect_types, etc.. Regards, Alan -- http://mail.python.org/mailman/listinfo/python-list

Re: inverse of a matrix with Fraction entries

2010-11-26 Thread casevh
On Nov 26, 2:11 pm, Steven D'Aprano steve +comp.lang.pyt...@pearwood.info wrote: On Fri, 26 Nov 2010 12:54:12 -0800, John Nagle wrote: For ordinary number crunching, rational arithmetic is completely inappropriate. Why? -- Steven As you perform repeated calculations with rationals, the

Re: Using Python for a demonstration in historical linguistics

2010-11-26 Thread Dax Bloom
On Nov 6, 6:41 am, Vlastimil Brom vlastimil.b...@gmail.com wrote: 2010/11/6 Dax Bloom bloom@gmail.com: Hello, In the framework of a project on evolutionary linguistics I wish to have a program to process words and simulate the effect of sound shift, for instance following the

Re: Using Python for a demonstration in historical linguistics

2010-11-26 Thread Dax Bloom
On Nov 6, 6:18 am, Peter Otten __pete...@web.de wrote: Peter Otten wrote: s = ... In the framework of a project onevolutionarylinguisticsI wish to ... have a program to process words and simulate the effect of sound ... shift, for instance following the Rask's-Grimm's rule. I look to

Re: Needed: Real-world examples for Python's Cooperative Multiple Inheritance

2010-11-26 Thread John Nagle
On 11/26/2010 4:21 PM, Mark Wooding wrote: John Naglena...@animats.com writes: I'd argue that a better implementation would require that when there's a name clash, you have to specify the class containing the name. In other words, if A is a subclass of B, then B.foo() overrides A.foo(). But

[issue10538] PyArg_ParseTuple(s*) does not always incref object

2010-11-26 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson krist...@ccpgames.com: The new s* code for PyArg_ParseTuple is used to fill a Py_buffer object from the arguments. This object must be relased using PyBuffer_Release() after use. However, if the object in the tuple does not support the new buffer

[issue10538] PyArg_ParseTuple(s*) does not always incref object

2010-11-26 Thread Kristján Valur Jónsson
Changes by Kristján Valur Jónsson krist...@ccpgames.com: -- versions: -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10538 ___ ___

[issue2504] Add gettext.pgettext() and variants support

2010-11-26 Thread Wichert Akkerman
Wichert Akkerman wich...@wiggy.net added the comment: I can help test changes for python 2.x. The python 3.x ecosystem is at least a year away from becoming interesting for me I'm afraid. -- ___ Python tracker rep...@bugs.python.org

[issue10538] PyArg_ParseTuple(s*) does not always incref object

2010-11-26 Thread Georg Brandl
Changes by Georg Brandl ge...@python.org: -- assignee: - pitrou nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10538 ___ ___

[issue10122] Documentation typo fix and a side question

2010-11-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: I don't waste my time by merging every little typo fix to the maintenance branches immediately; I rather merge them all at once every now and then. You will certainly understand that nobody is harmed by a stray d, even if it has a pointy tip.

[issue10299] Add index with links section for built-in functions

2010-11-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Dividing the table in sections makes sense to me; it provides the kind of grouping that is helpful sometimes, but cannot be kept when sorting alphabetically. So when the table is grouped, the actual docs can remain alphabetized. --

[issue10526] Minor typo in What's New in Python 2.7

2010-11-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Thanks, fixed in r86794. -- nosy: +georg.brandl resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10526

[issue9312] Fix usage of :option: markup in stdlib ReST docs

2010-11-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Yes, you're right; you could have linked to the correct -c option by using this form: :option:`unittest -c` -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9312

[issue10420] Document of Bdb.effective is wrong.

2010-11-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Thanks, fixed in r86798. -- nosy: +georg.brandl resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10420

[issue10172] code block has no syntax coloring

2010-11-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: This is because the Python used to render doesn't recognize the new-style exception catching; this will be fine once the system is upgraded to 2.6. -- nosy: +georg.brandl resolution: - later status: open - closed

[issue5211] Fix complex type to avoid coercion in 2.7.

2010-11-26 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: I think that's expected behaviour. Note that int vs float behaves in the same way as float vs complex: class xint(int): ... def __radd__(self, other): ... print __radd__ ... return 42 ... 3 + xint(5) __radd__ 42 3.0

[issue10535] Enable warnings by default in unittest

2010-11-26 Thread Davide Rizzo
Changes by Davide Rizzo sor...@gmail.com: -- nosy: +davide.rizzo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10535 ___ ___ Python-bugs-list

[issue1059244] distutil bdist hardcodes the python location

2010-11-26 Thread anatoly techtonik
anatoly techtonik techto...@gmail.com added the comment: As I can't reopen this issue, I'd like to ask for another opinion before closing this ticket. I think it's closed prematurely. For the bare minimum there should be a link to corresponding issue in distutils2 project. --

[issue10510] distutils upload/register should use CRLF in HTTP requests

2010-11-26 Thread Brian Jones
Brian Jones bkjo...@gmail.com added the comment: Sure. I'll create a patch in the next few days and submit it. Thanks for the link to the guidelines. :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10510

[issue1059244] distutil bdist hardcodes the python location

2010-11-26 Thread Tarek Ziadé
Tarek Ziadé ziade.ta...@gmail.com added the comment: I am +1 with what Eric said. I'd suggest that you send a mail to teh distutils2 development mailing list to make some proposals. -- ___ Python tracker rep...@bugs.python.org

[issue10510] distutils upload/register should use CRLF in HTTP requests

2010-11-26 Thread Brian Jones
Brian Jones bkjo...@gmail.com added the comment: So... have I missed a memo, or is it currently impossible to test the current svn version of distutils in the current svn version of Python? The tests for (at least) register and upload are written using Python 2.x syntax and modules. How are

[issue10510] distutils upload/register should use CRLF in HTTP requests

2010-11-26 Thread Tarek Ziadé
Tarek Ziadé ziade.ta...@gmail.com added the comment: If you can make your server work with the current implementation, I'd rather not change this in distutils but in distutils2. Distutils is frozen and we make only bug fixes. By bug fix I mean anything that is a bug. A non-strict

[issue10538] PyArg_ParseTuple(s*) does not always incref object

2010-11-26 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10538 ___ ___ Python-bugs-list mailing

[issue6983] Add specific get_platform() for freebsd

2010-11-26 Thread Tarek Ziadé
Changes by Tarek Ziadé ziade.ta...@gmail.com: -- components: +Distutils2, Library (Lib) -Distutils ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6983 ___

[issue10510] distutils upload/register should use CRLF in HTTP requests

2010-11-26 Thread Brian Jones
Brian Jones bkjo...@gmail.com added the comment: If it's not a bug in distutils1, I imagine it will not be a bug in distutils2, since that will also presumably work with PyPI, and PyPI will be the single solitary supported implementation of the service? I also don't see distutils2 in this

[issue10510] distutils upload/register should use CRLF in HTTP requests

2010-11-26 Thread Tarek Ziadé
Tarek Ziadé ziade.ta...@gmail.com added the comment: If it's not a bug in distutils1, I imagine it will not be a bug in distutils2 Yes that would be a feature request. we would be happy to add. e.g. make the commands works with server X ou server Y. I also don't see distutils2 in this list

[issue10539] Regular expression not checking 'range' element on 1st char in string.

2010-11-26 Thread Jamie Murray
New submission from Jamie Murray txr...@gmail.com: The first char in a word is omitted from being checked against the 'range' element of the 1st part of this expression. The second char is properly checked to see if it's in range # Desired safe string to expect goodString =

[issue10540] test_shutil fails on Windows after r86733

2010-11-26 Thread Brian Curtin
New submission from Brian Curtin cur...@acm.org: My build slave shows a test failure at test_dont_copy_file_onto_link_to_itself. This happens because the implementation of _samefile in Lib/shutil.py (line 70) doesn't work for Windows hard links. Patch on the way. -- assignee:

[issue10541] regrtest.py -T broken

2010-11-26 Thread Walter Dörwald
New submission from Walter Dörwald wal...@livinglogic.de: Running regrtest.py with coverage option seems to be broken for the py3k branch at the moment. Run the following commands on the shell: wget http://svn.python.org/snapshots/python3k.tar.bz2 tar xjf python3k.tar.bz2 cd python ./configure

[issue10542] Py_UNICODE_NEXT and other macros for surrogates

2010-11-26 Thread Alexander Belopolsky
New submission from Alexander Belopolsky belopol...@users.sourceforge.net: As discussed in issue 10521 and the sprawling len(chr(i)) = 2? thread [1] on python-dev, many functions in python library behave differently on narrow and wide builds. While there are unavoidable differences such as

[issue9200] str.isprintable() is always False for large code points

2010-11-26 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: AFAICT, all ctype methods (isalpha, isdigit, etc.) have the same problem. I posted a patch at issue10542 that introduces a Py_UNICODE_NEXT() macro that can help fixing all these methods. I am adding #10542 as a

[issue10542] Py_UNICODE_NEXT and other macros for surrogates

2010-11-26 Thread Alexander Belopolsky
Changes by Alexander Belopolsky belopol...@users.sourceforge.net: -- nosy: +haypo, loewis ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10542 ___

[issue10540] test_shutil fails on Windows after r86733

2010-11-26 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: Here is a patch. os.path.samefile and hard links don't work for Windows the same way they do for Mac/Linux. In the case where we are on Windows and a link comes into the _samefile function, check that it's a link and then use

[issue10543] Test discovery (unittest) does not work with jython

2010-11-26 Thread Michael Foord
Changes by Michael Foord mich...@voidspace.org.uk: -- assignee: - michael.foord components: +Library (Lib) type: - behavior versions: +Python 2.7, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10543

[issue9509] argparse FileType raises ugly exception for missing file

2010-11-26 Thread SilentGhost
Changes by SilentGhost michael.mischurow+...@gmail.com: Removed file: http://bugs.python.org/file19815/test_argparse.py.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9509 ___

[issue9509] argparse FileType raises ugly exception for missing file

2010-11-26 Thread SilentGhost
SilentGhost michael.mischurow+...@gmail.com added the comment: On windows proposed changes to Lib/test/test_argparse.py cause it to enter an infinite loop in TempDirMixin.tearDown method. As it seemed exclusively Windows issue, this new patch replaces while loop with the ignore_errors

[issue10543] Test discovery (unittest) does not work with jython

2010-11-26 Thread Michael Foord
Michael Foord mich...@voidspace.org.uk added the comment: Won't need fixing in 3.2. The __pycache__ changes mean that the module.__file__ no longer points to the compiled bytecode file. -- versions: -Python 3.2 ___ Python tracker

[issue10535] Enable warnings by default in unittest

2010-11-26 Thread Michael Foord
Michael Foord mich...@voidspace.org.uk added the comment: I'm also thinking that it might be better to include the name of the deprecated method in the message and use three filters for fail* methods, assert* methods, and the assert*Regexp* methods that will be deprecated. That sounds good,

[issue10539] Regular expression not checking 'range' element on 1st char in string.

2010-11-26 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: I'm not sure I understand. The output I get is: f42e6be1-29bf-4f3c-ba58-1ae1d9ca5f88 g42e6be1-29bf-4f3c-ba58-1ae1d9ca5f88 False The first string matches. The second string matches because the leading g is being matched by \w. The third string

[issue5211] Fix complex type to avoid coercion in 2.7.

2010-11-26 Thread Blair
Blair bidih...@gmail.com added the comment: I see your point Mark, however it does not seem to be the right way to do this. Are you aware that Python has formally specified this behaviour somewhere? I could not find an explicit reference in the documentation. The problem that has been fixed is

[issue10539] Regular expression not checking 'range' element on 1st char in string.

2010-11-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: I don't think so; closing as invalid. -- nosy: +georg.brandl resolution: - invalid status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10539

[issue10539] Regular expression not checking 'range' element on 1st char in string.

2010-11-26 Thread Jamie Murray
Jamie Murray txr...@gmail.com added the comment: Apologies, sincere and most humble apolgies doh! On 26 Nov 2010 18:51, Georg Brandl rep...@bugs.python.org wrote: Georg Brandl ge...@python.org added the comment: I don't think so; closing as invalid. -- nosy: +georg.brandl

[issue10544] yield expression inside generator expression does nothing

2010-11-26 Thread Inyeol Lee
New submission from Inyeol Lee inyeol@gmail.com: Simple coroutine with for loop works: def pack_a(): while True: L = [] for i in range(2): L.append((yield)) print(L) pa = pack_a() next(pa) pa.send(1) pa.send(2) [1, 2] If

[issue10532] A bug related to matching the empty string

2010-11-26 Thread Ned Deily
Ned Deily n...@acm.org added the comment: Closing this issue since it appears to not be a bug. -- nosy: +ned.deily resolution: - invalid status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10532

[issue10545] remove or rewrite Using Backslash to Continue Statements anti-idiom

2010-11-26 Thread rurpy the second
New submission from rurpy the second ru...@yahoo.com: The Python HOWTOs-Idioms and Anti-Idioms has a section Using Backslash to Continue Statements. It says that line continuation is dangerous and gives two reasons. 1. Hard to see a space after the backslash. This is not dangerous as it cause

[issue10537] OS X IDLE 2.7rc1 from 64-bit installer hangs when you paste something.

2010-11-26 Thread Ned Deily
Ned Deily n...@acm.org added the comment: This appears to be another variant of the IDLE, OS X 10.6, 64-bit, Apple-supplied Tk 8.5 problems. As a workaround, you can re-install 2.7rc1 using the 32-bit-only installer; IDLE there does not exhibit these problems. -- assignee: -

[issue10546] UTF-16-LE and UTF-16-BE support non-BMP characters

2010-11-26 Thread STINNER Victor
New submission from STINNER Victor victor.stin...@haypocalc.com: Python3 doc tells that UTF-16-LE and UTF-16-BE only support BMP characters. What? I think that it is wrong. It was maybe wrong with Python2 and narrow build (unichr() only supports BMP characters), but it is no more true in

[issue1178] IDLE - add paste code functionality

2010-11-26 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: I would really like something like this -- for 3.2b1 next week. I am constantly running posted interactive code and the lack of this is a major nuisance. There seems to be a glitch in how the editor deals with ' ' when trying to delete it.

[issue1178] IDLE - add paste code functionality

2010-11-26 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: An alternative approach would be to leave pasting alone but add a 'Convert interactive code' option to the format menu, with keycode alt-v (not currently used as far as I can see). -- ___ Python

[issue2504] Add gettext.pgettext() and variants support

2010-11-26 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: New features don’t go into stable branches. The patch is also reviewable at http://codereview.appspot.com/3340041 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2504

[issue10521] str methods don't accept non-BMP fillchar on a narrow Unicode build

2010-11-26 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: As a practical matter, I think that for at least the next decade, people are at least as likely to want to fill with a composed, multi-BMP-codepoint 'char' (grapheme) as with a non-BMP char. So to me, failure with the latter is no worse than

[issue10537] OS X IDLE 2.7rc1 from 64-bit installer hangs when you paste something.

2010-11-26 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: Is this a duplicate of other issues (close?)? Is this an Apple problem beyond our control (close?)? -- nosy: +terry.reedy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10537

[issue9312] Fix usage of :option: markup in stdlib ReST docs

2010-11-26 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Great, thanks! New markup committed as r86823, long lines rewrapped in r86824 (along with a few minor touch-ups). I think we’re good now, I’ll backport shortly. -- ___ Python tracker

[issue1059244] distutil bdist hardcodes the python location

2010-11-26 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Distutils2 bugs are tracked here (bugs.python.org), feel free to open a feature request for the Distutils2 component. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1059244

[issue10521] str methods don't accept non-BMP fillchar on a narrow Unicode build

2010-11-26 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: On Fri, Nov 26, 2010 at 6:37 PM, Terry J. Reedy rep...@bugs.python.org wrote: Terry J. Reedy tjre...@udel.edu added the comment: As a practical matter, I think that for at least the next decade, people are at least as

[issue10521] str methods don't accept non-BMP fillchar on a narrow Unicode build

2010-11-26 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: I think these macros would be a reasonable approach. I think str.center, etc. should support non-BMP chars, because to not do so can raise an exception. Supporting composed graphemes seems like another problem altogether. And while we could fix

[issue10542] Py_UNICODE_NEXT and other macros for surrogates

2010-11-26 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: In addition to the proposed Py_UNICODE_NEXT and Py_UNICODE_PUT_NEXT, str.__format__ would also need a function that tells it how many Py_UNICODEs are needed to store a given Py_UCS4. -- ___ Python

[issue10542] Py_UNICODE_NEXT and other macros for surrogates

2010-11-26 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: On Fri, Nov 26, 2010 at 7:27 PM, Eric Smith rep...@bugs.python.org wrote: .. In addition to the proposed Py_UNICODE_NEXT and Py_UNICODE_PUT_NEXT,  str.__format__ would also need a function that tells it how many

[issue9264] trace.py documentation is incomplete

2010-11-26 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Divided command-line options logically into sub-sections and improved their explanations Using the program/cmdoption combo may be a good idea here. -- nosy: +eric.araujo ___ Python tracker

[issue10542] Py_UNICODE_NEXT and other macros for surrogates

2010-11-26 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: I'd need access to this without having to build a PyUnicodeObject, for efficiency. But it sounds like it does have the basic functionality I need. For my use I'd really need it to take the result of Py_UNICODE_NEXT. Something like: Py_ssize_t

[issue10299] Add index with links section for built-in functions

2010-11-26 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Possible groups: Types constructors: bool, bytearray, bytes, complex, dict, float, frozenset, int, list, memoryview, object, range, set, slice, str, tuple Mathematical functions: abs, bin, divmod, hex, oct, pow, round Working with sequences:

[issue10542] Py_UNICODE_NEXT and other macros for surrogates

2010-11-26 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: On Fri, Nov 26, 2010 at 7:45 PM, Eric Smith rep...@bugs.python.org wrote: .. For my use I'd really need it to take the result of Py_UNICODE_NEXT. Something like: Py_ssize_t Py_UNICODE_NUM_NEEDED(Py_UCS4 c) and it

[issue10541] regrtest.py -T broken

2010-11-26 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: -- nosy: +belopolsky ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10541 ___ ___

  1   2   >