Re: [bug] imaplib case sensitive

2012-02-22 Thread Giampaolo Rodolà
Please file a bug on http://bugs.python.org/ --- Giampaolo http://code.google.com/p/pyftpdlib/ http://code.google.com/p/psutil/ http://code.google.com/p/pysendfile/ Il 21 febbraio 2012 10:31, Petite Abeille ha scritto: > Hello, > > Looks like imaplib is case sensitive, even though the IMAP proto

Re: Python LOC, .exe size, and refactoring

2012-02-22 Thread Chris Angelico
On Wed, Feb 22, 2012 at 4:29 PM, Steven D'Aprano wrote: > While I think 60MB for a basic calculator app is taking the piss, this is > 2011 not 1987 and we don't have to support floppy disks any more. 11MB > for a GUI app is nothing to be worried about. That takes, what, 3 minutes > to download eve

Re: xlwt 0.7.3 released!

2012-02-22 Thread Chris Withers
On 21/02/2012 11:02, Karim wrote: Is there any chance that xlrd read .xlsx format I believe this is planned for the next major release. and arrive to decode special unicode instead of firing some unicode Exception? Not heard of this, I suggest you explain the problem you're having on the

Re: [pyxl] xlrd 0.7.2 released!

2012-02-22 Thread Chris Withers
On 22/02/2012 00:37, python-ex...@raf.org wrote: was good for previous versions. two reasons that spring to mind immediately are: - it makes it much easier to tell what version is installed - it makes it much easier to uninstall the package i know that both of these are things that the pyth

ANN: python-ldap 2.4.8

2012-02-22 Thread Michael Ströder
Find a new release of python-ldap: http://pypi.python.org/pypi/python-ldap/2.4.8 python-ldap provides an object-oriented API to access LDAP directory servers from Python programs. It mainly wraps the OpenLDAP 2.x libs for that purpose. Additionally it contains modules for other LDAP-related st

Re: Python as a default shell, replacement of bash, sh, cmd ?

2012-02-22 Thread Grant Edwards
On 2012-02-22, Kyle T. Jones wrote: > On 2/19/12 2:16 AM, SherjilOzair wrote: >> Well, if not modify python itself, I was thinking of making another shell, >> which borrows a lot from python, something like merging bash and python. >> such that I can do `cd ~/Desktop/dev` and `for i in open('fil

[ANN] Python/Cython/SDL 2D Game Engine

2012-02-22 Thread Gabriel Jacobo
Hello list, I wanted to let you know about my pet project for the last few months, a multiplatform (Linux64/Win32/Android at the moment), Python/Cython/SDL open source 2D game engine called "Ignifuga". The source code mixes Python and Cython code, then uses Cython to convert everything to C, and co

Inheriting from OrderedDict causes problem

2012-02-22 Thread Bruce Eckel
Notice that both classes are identical, except that one inherits from dict (and works) and the other inherits from OrderedDict and fails. Has anyone seen this before? Thanks. import collections class Y(dict): def __init__(self, stuff): for k, v in stuff: self[k] = v # Thi

Re: Inheriting from OrderedDict causes problem

2012-02-22 Thread Peter Otten
Bruce Eckel wrote: > Notice that both classes are identical, except that one inherits from > dict (and works) and the other inherits from OrderedDict and fails. > Has anyone seen this before? Thanks. > > import collections > > class Y(dict): > def __init__(self, stuff): > for k, v in

Re: generate Windows exe on Linux

2012-02-22 Thread Waldek M.
On Wed, 22 Feb 2012 04:12:29 -0800 (PST), Plumo wrote: > I have a python script using only the standard libraries. > Currently I use a Windows VM to generate exe's, which is cumbersome. And what exactly *is* this exe about? > Has anyone had success generating exe's from within Linux? That doesn'

Questionnaire on motivation analysis of open source and open content

2012-02-22 Thread George Tsinarakis
Dear Sirs, We are researchers in Technical University of Crete and our current research is in the field of motivation analysis of open source and open content software projects participants. We would like to ask you to fill a questionnaire and forward it to people involved in such teams and p

Re: Inheriting from OrderedDict causes problem

2012-02-22 Thread Bruce Eckel
On Feb 22, 10:10 am, Peter Otten <__pete...@web.de> wrote: > Looks like invoking OrderedDict.__init__() is necessary: > > >>> from collections import OrderedDict > >>> class X(OrderedDict): > > ...     def __init__(self, stuff): > ...             super(X, self).__init__() > ...             for k, v

Re: generate Windows exe on Linux

2012-02-22 Thread Jérôme
Wed, 22 Feb 2012 18:19:12 +0100 Waldek M. a écrit: > On Wed, 22 Feb 2012 04:12:29 -0800 (PST), Plumo wrote: > > I have a python script using only the standard libraries. > > Currently I use a Windows VM to generate exe's, which is cumbersome. > > And what exactly *is* this exe about? Whatever.

Re: generate Windows exe on Linux

2012-02-22 Thread Alec Taylor
http://www.pyinstaller.org/ or http://cx-freeze.sourceforge.net/ You can also run py2exe in WINE On Thu, Feb 23, 2012 at 4:42 AM, Jérôme wrote: > Wed, 22 Feb 2012 18:19:12 +0100 > Waldek M. a écrit: > >> On Wed, 22 Feb 2012 04:12:29 -0800 (PST), Plumo wrote: >> > I have a python script using o

Python math is off by .000000000000045

2012-02-22 Thread Alec Taylor
Simple mathematical problem, + and - only: >>> 1800.00-1041.00-555.74+530.74-794.95 -60.9500045 That's wrong. Proof http://www.wolframalpha.com/input/?i=1800.00-1041.00-555.74%2B530.74-794.95 -60.95 aka (-(1219/20)) Is there a reason Python math is only approximated? - Or is this a bug?

Re: Python math is off by .000000000000045

2012-02-22 Thread Mark Lawrence
On 22/02/2012 18:13, Alec Taylor wrote: Simple mathematical problem, + and - only: 1800.00-1041.00-555.74+530.74-794.95 -60.9500045 That's wrong. Proof http://www.wolframalpha.com/input/?i=1800.00-1041.00-555.74%2B530.74-794.95 -60.95 aka (-(1219/20)) Is there a reason Python math i

Re: Python math is off by .000000000000045

2012-02-22 Thread Christian Heimes
Am 22.02.2012 19:13, schrieb Alec Taylor: > Simple mathematical problem, + and - only: > 1800.00-1041.00-555.74+530.74-794.95 > -60.9500045 > > That's wrong. That's only the correct answer for unlimited precision, not for IEEE-754 semantics. http://en.wikipedia.org/wiki/IEEE_754 >

Re: Python math is off by .000000000000045

2012-02-22 Thread Ian Kelly
On Wed, Feb 22, 2012 at 11:13 AM, Alec Taylor wrote: > Simple mathematical problem, + and - only: > 1800.00-1041.00-555.74+530.74-794.95 > -60.9500045 > > That's wrong. > > Proof > http://www.wolframalpha.com/input/?i=1800.00-1041.00-555.74%2B530.74-794.95 > -60.95 aka (-(1219/20)) >

Re: Python math is off by .000000000000045

2012-02-22 Thread Benjamin Kaplan
On Feb 22, 2012 1:16 PM, "Alec Taylor" wrote: > > Simple mathematical problem, + and - only: > > >>> 1800.00-1041.00-555.74+530.74-794.95 > -60.9500045 > > That's wrong. > > Proof > http://www.wolframalpha.com/input/?i=1800.00-1041.00-555.74%2B530.74-794.95 > -60.95 aka (-(1219/20)) > > Is

Re: Python math is off by .000000000000045

2012-02-22 Thread Chris Rebert
On Wed, Feb 22, 2012 at 10:13 AM, Alec Taylor wrote: > Simple mathematical problem, + and - only: > 1800.00-1041.00-555.74+530.74-794.95 > -60.9500045 > > That's wrong. Welcome to the world of finite-precision binary floating-point arithmetic then! Reality bites. > Proof > http://ww

Re: Python math is off by .000000000000045

2012-02-22 Thread nn
On Feb 22, 1:13 pm, Alec Taylor wrote: > Simple mathematical problem, + and - only: > > >>> 1800.00-1041.00-555.74+530.74-794.95 > > -60.9500045 > > That's wrong. > > Proofhttp://www.wolframalpha.com/input/?i=1800.00-1041.00-555.74%2B530.74-... > -60.95 aka (-(1219/20)) > > Is there a reas

Re: Python math is off by .000000000000045

2012-02-22 Thread Jussi Piitulainen
Alec Taylor writes: > Simple mathematical problem, + and - only: > > >>> 1800.00-1041.00-555.74+530.74-794.95 > -60.9500045 > > That's wrong. Not by much. I'm not an expert, but my guess is that the exact value is not representable in binary floating point, which most programming langua

Re: Python math is off by .000000000000045

2012-02-22 Thread Grant Edwards
On 2012-02-22, Alec Taylor wrote: > Simple mathematical problem, + and - only: > 1800.00-1041.00-555.74+530.74-794.95 > -60.9500045 > > That's wrong. Oh good. We haven't have this thread for several days. > Proof > http://www.wolframalpha.com/input/?i=1800.00-1041.00-555.74%2B530.

Re: Python as a default shell, replacement of bash, sh, cmd ?

2012-02-22 Thread Steven D'Aprano
On Wed, 22 Feb 2012 15:31:10 +, Grant Edwards wrote: > On 2012-02-22, Kyle T. Jones > wrote: >> On 2/19/12 2:16 AM, SherjilOzair wrote: >>> Well, if not modify python itself, I was thinking of making another >>> shell, which borrows a lot from python, something like merging bash >>> and pytho

Re: generate Windows exe on Linux

2012-02-22 Thread Gelonida N
On 02/22/2012 07:05 PM, Alec Taylor wrote: > http://www.pyinstaller.org/ > > or > > http://cx-freeze.sourceforge.net/ > > You can also run py2exe in WINE > You want to say, that I could install python 2.6 some packages like win32api PyQt and tand py2exe under Wine and then compile it. Did yo

Re: Python math is off by .000000000000045

2012-02-22 Thread Steven D'Aprano
On Wed, 22 Feb 2012 19:26:26 +0100, Christian Heimes wrote: > Python uses the platforms double precision float datatype. Floats are > almost never exact. Well, that's not quite true. Python floats are always exact. They just may not be exactly what you want :) Pedantic-but-unhelpful-as-always-l

Re: generate Windows exe on Linux

2012-02-22 Thread Stefan Behnel
Gelonida N, 22.02.2012 23:25: > On 02/22/2012 07:05 PM, Alec Taylor wrote: >> http://www.pyinstaller.org/ >> >> or >> >> http://cx-freeze.sourceforge.net/ >> >> You can also run py2exe in WINE >> > > You want to say, that I could install python 2.6 > some packages like win32api > PyQt and tand py2

Re: [pyxl] xlrd 0.7.2 released!

2012-02-22 Thread python-excel
Chris Withers wrote: > On 22/02/2012 00:37, python-ex...@raf.org wrote: > >was good for previous versions. two reasons that spring to mind > >immediately are: > > > > - it makes it much easier to tell what version is installed > > - it makes it much easier to uninstall the package > > > >i know

Re: [pyxl] xlrd 0.7.2 released!

2012-02-22 Thread Adrian Klaver
On Wednesday, February 22, 2012 5:22:45 am Chris Withers wrote: > On 22/02/2012 00:37, python-ex...@raf.org wrote: > > was good for previous versions. two reasons that spring to mind > > > > immediately are: > > - it makes it much easier to tell what version is installed > > - it makes it much

distutils + mercurial good practice question

2012-02-22 Thread Steven D'Aprano
distutils generates a number of files automatically in my projects, including MANIFEST, build/* and dist/* Is there any reason why I would want or need to track them in mercurial? I currently have this .hgignore file: syntax: glob *.pyc *~ exclude/* build/* dist/* MANIFEST Good practice or b

ANN: pyprimes 0.1 released

2012-02-22 Thread Steven D'Aprano
I am happy to announce the first public release of pyprimes, a pure- Python module for generating prime numbers, primality tests, and prime factorisation. http://pypi.python.org/pypi/pyprimes/0.1.1a With pyprimes, you can compare a number of algorithms for generating and testing primes. It incl

Python Game Programming Challenge (PyWeek) #14 is coming! [corrected dates]

2012-02-22 Thread Richard Jones
Note: this email corrects the dates given in the previous announcement. The 14th Python Game Programming Challenge (PyWeek) is coming. It'll run from the 6th to the 13th of May. Not April as previously announced. http://pyweek.org/14/ New user registration is NOT YET OPEN. It will open one mont

Re: generate Windows exe on Linux

2012-02-22 Thread Miki Tebeka
> Having said that, Wine is actually surprisingly capable these days. It > won't always run the latest release of our all-time favourite WYGIWYD > character pushing or number layouting programs from MS-Office fame, but at > least older versions of many a program tend to work rather nicely. Even new

storing in list and retrieving.

2012-02-22 Thread Smiley 4321
I need to write two file using python script as below - 1. Store.py: Write a script to store a list say "store_list = ["Apple", "Orange", "PineApple". “and so on” ]" to disk. 2. Retrieve.py: Read the object stored in the ‘Store.py’ file and print the contents of this list. I have to run on L

Re: storing in list and retrieving.

2012-02-22 Thread Chris Angelico
On Thu, Feb 23, 2012 at 5:24 PM, Smiley 4321 wrote: > I need to write two file using python script as below - > > 1. Store.py: Write a script to store a list say "store_list = ["Apple", > "Orange", "PineApple". “and so on” ]" to disk. > > 2. Retrieve.py: Read the object stored in the ‘Store.py’ fi

Re: generate Windows exe on Linux

2012-02-22 Thread Plumo
thanks Jérôme. Closest I have found is pyinstaller added support for cross-compiling a year ago by mounting a Windows partition on Linux: https://groups.google.com/forum/?fromgroups#!topic/pyinstaller/KISZP5sHCWg But it was not stable so will be removed: https://groups.google.com/forum/?fromgrou

asynchronous downloading

2012-02-22 Thread Plumo
I want to download content asynchronously. This would be straightforward to do threaded or across processes, but difficult asynchronously so people seem to rely on external libraries (twisted / gevent / eventlet). (I would use gevent under different circumstances, but currently need to stick t