ANN: emacs-for-python 0.2.1 released

2011-04-02 Thread Gabriele Lanaro
I'm pleased to announce the 0.2.1 release of emacs-for-python *What is emacs-for-python?* It's a collection of emacs extensions and settings to quickly setup the editor for python development. *Main features included:* - snippets - pymacs - ropemacs - auto-completion - on the fly

Re: Speed-up for loops

2010-09-04 Thread Gabriele Lanaro
Maybe for the simple sum you can just use the sum builtin: python -m timeit -s 'sum((10,)*1)' 1000 loops, best of 3: 0.0985 usec per loop About the loop in general it's a good practice to use list comprehension and generator expressions 2010/9/2 Michael Kreim > Hi, > > I was comparing

[ANN] Emacs For Python 0.1, collection of emacs extensions for python development

2010-07-02 Thread Gabriele Lanaro
Emacs For Python 0.1 Emacs for python (epy) is a collection of emacs extensions for python development, yet ready and configured for you. It includes also tweaks to commonly used extension to provide extra functionality and fast bug correction. There are also sane configuration that helps you ge

[ANN]: Emacs For Python 0.1, collection of emacs extensions for python development

2010-07-01 Thread Gabriele Lanaro
Emacs For Python 0.1 Emacs for python (epy) is a collection of emacs extensions for python development, yet ready and configured for you. It includes also tweaks to commonly used extension to provide extra functionality and fast bug correction. There are also sane configuration that helps you ge

Python distributing localization files

2010-06-17 Thread Gabriele Lanaro
Hi, I want to localize my application (a pygtk gui app), what's the best way to distribute and install localization files? I'm currently using `distribute` to package it. Any suggestion? -- http://mail.python.org/mailman/listinfo/python-list

Re: Syntax problem - cannot solve it by myself

2010-06-08 Thread Gabriele Lanaro
The print function you're trying to use is for python 3 version only, If you want to keep reading the book, install python 3, else take a book that covers python 2.x syntax 2010/6/8 Deadly Dirk > I am a total beginner with Python. I am reading a book ("The Quick Python > Book", 2nd edition, by V

Re: GUIs - A Modest Proposal

2010-06-06 Thread Gabriele Lanaro
I'd really like to s/tkinter/WxWidgets/g, the multiplatformness is (almost) the same but wx looks infinitely better. IMHO a good intention is to best the API of wx. Anyway, GUI programmers usually choose the toolkit (often 3rd party) more appropriate for the situation, wether it is or not in the st

Re: Replace in large text file ?

2010-06-05 Thread Gabriele Lanaro
A module designed to do this is fileinput: http://docs.python.org/library/fileinput.html The approach is the same as the other except that it's in the standard library. 2010/6/5 Paul Rubin > Steve writes: > > Remove all comma's > > Replace all @ with comma's > > Save as a new file. > > The si

Re: Vote to Add Python Package "pubsub" to the Python Standard Library

2010-06-02 Thread Gabriele Lanaro
I definitvely vote for adding such a package to the stdlib (or at least a symilar publish/subscrive and observer implementation). It's useful in a wide range of programs. 2010/6/2 Carl Banks > On May 26, 4:26 am, Tom wrote: > > I vote for adding the Python package "pubsub" to the Python standa

Problems with relative imports and pep 366

2010-05-31 Thread Gabriele Lanaro
I've yet asked this question on SO, I'll copy the contents: I have a "canonical file structure" like that (I'm giving sensible names to ease the reading): mainpack/ __main__.py __init__.py - helpers/ __init__.py path.py - network/ __init__.py clientlib.py serv