simplejson: alternate encoder not called enought

2009-03-21 Thread Pierre Hanser
hello I'm trying to use simplejson to encode some python objects using simplejson dumps method. The dumps method accept a cls parameter to specify an alternate encoder. But it seems that this alternate encoder is called only as a last resort, if object type is not int, string, and all other basic

Re: Which SOAP module?

2009-01-04 Thread Pierre Hanser
Ralf Schoenian a écrit : > Roy Smith wrote: >> I'm starting to play with SOAP. The zeroth question that needs >> answering is, "Which SOAP module should I use?" There seem to be a >> number of different ones to pick from. Any suggestions? >> >> > It depends on whether you want to write a client

Re: status of Programming by Contract (PEP 316)?

2007-09-01 Thread Pierre Hanser
Carl Banks a écrit : > > This is starting to sound silly, people. Critical is a relative term, > and one project's critical may be anothers mundane. Sure a flaw in your > flagship product is a critical problem *for your company*, but are you > really trying to say that the criticalness of a b

Re: PIL cutting off letters

2007-06-16 Thread Pierre Hanser
Matt Haggard a écrit : > I'm using PIL (Python Imaging Library) to generate button images. > They consist of a left end image, a middle, repeating image and a > right side image anyway, that's not important > > I'm using a TTF font for the text of the button (Verdana.TTF) and it > keeps cuttin

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-15 Thread Pierre Hanser
[EMAIL PROTECTED] a écrit : > On May 15, 3:28 pm, René Fleschenberg <[EMAIL PROTECTED]> wrote: >> We all know what the PEP is about (we can read). The point is: If we do >> not *need* non-English/ASCII identifiers, we do not need the PEP. If the >> PEP does not solve an actual *problem* and still i

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-15 Thread Pierre Hanser
hello i work for a large phone maker, and for a long time we thought, very arrogantly, our phones would be ok for the whole world. After all, using a phone uses so little words, and some of them where even replaced with pictograms! every body should be able to understand appel, bis, renvoi, mévo,

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-15 Thread Pierre Hanser
René Fleschenberg a écrit : > Your example does not prove much. The fact that some people use > non-ASCII identifiers when they can does not at all prove that it would > be a serious problem for them if they could not. > i have to make orthograph mistakes in my code to please you? -- Pi

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-15 Thread Pierre Hanser
René Fleschenberg a écrit : > IMO, the burden of proof is on you. If this PEP has the potential to > introduce another hindrance for code-sharing, the supporters of this PEP > should be required to provide a "damn good reason" for doing so. So far, > you have failed to do that, in my opinion. All

PEP 3131: Ascii-English is like coca-cola!

2007-05-14 Thread Pierre Hanser
This pep is not technical, or at least not only. It has larger implications about society model we want. Let me explain with an analogy: let's compare 'ascii english' to coca-cola. It's available nearly everywhere. It does not taste good at first try, and is especially repulsive to young childre

Re: popen2

2005-10-29 Thread Pierre Hanser
Grant Edwards a écrit : > On 2005-10-29, Piet van Oostrum <[EMAIL PROTECTED]> wrote: > >>>"g.franzkowiak" <[EMAIL PROTECTED]> (gf) wrote: >> >>>gf> If starts a process with popen2.popen3('myprogram') and myprogram.exe is >>>gf> running before, I've a connection to the second process, not to t

Re: For American numbers

2005-02-12 Thread Pierre Hanser
Peter Hansen wrote: Scott David Daniels wrote: Kind of fun exercise (no good for British English). def units(value, units='bytes'): magnitude = abs(value) if magnitude >= 1000: for prefix in ['kilo mega giga tera peta ' 'exa zetta yotta').s