Pep 342 (val = yield MyGenerator(foo)), synchronous os.system() that doesn't block gui event loops

2009-07-20 Thread Ville Vainio
Has anyone implementing something like what the subject line indicates? The idea: To run functions that execute a series of system commands without blocking the ui, *and* without adding state machine logic. The syntax would be something like: def work(): showstatus("building") r = yield ru

Re: LGPL license for Qt 4.5

2009-01-17 Thread Ville Vainio
On Jan 14, 2:57 pm, sturlamolden wrote: > According to a Norwegian publication, Nokia will release Qt under LGPL > as of version 4.5. > > If I had stocks in Riverbank Computing ltd., I would sell them now... Isn't that a tad thankless and premature? It may be that the "support" aspect needs to

Re: python vs. grep

2008-05-09 Thread Ville Vainio
On May 8, 8:11 pm, Ricardo Aráoz <[EMAIL PROTECTED]> wrote: > All these examples assume your regular expression will not span multiple > lines, but this can easily be the case. How would you process the file > with regular expressions that span multiple lines? re.findall/ finditer, as I said earl

Re: python vs. grep

2008-05-07 Thread Ville Vainio
On May 6, 10:42 pm, Anton Slesarev <[EMAIL PROTECTED]> wrote: > flines = (line for line in f if pat.search(line)) What about re.findall() / re.finditer() for the whole file contents? -- http://mail.python.org/mailman/listinfo/python-list

Re: ]ANN[ Vellum 0.16: Lots Of Documentation and Watching

2008-05-07 Thread Ville Vainio
On May 6, 11:27 pm, hdante <[EMAIL PROTECTED]> wrote: > GPL can mix with other free software licenses, so people who write > BSD code and do not wish to remain BSD clean are free to use GPL'd > code. That's the important point. No, it can't. It can only mix through aggregation, i.e. you can ship

Re: is Pylons alive?

2008-04-10 Thread Ville Vainio
On Apr 9, 2:25 pm, Mage <[EMAIL PROTECTED]> wrote: > Before spending much time for investigating, I would like to ask you: is > Pylons the framework I look for if I want to come back to Python and > develop MVC web apps? Why not play with Django and the Google App Engine that everyone is raving a

pywin32 vista installer fix & general distutils installer name bug

2008-04-09 Thread Ville Vainio
I just noticed that pywin32 does not work with vista directly (tried import win32clipboard, => ImportError). The problem is the installer name; it's the usual pywin32-210-win32-py2.5.exe It needs to be renamed to: pywin32-210.win32-setup-py2.5.exe In order for vista to catch it as "installer".

Re: ANN: Leo 4.4.8 final

2008-04-06 Thread Ville Vainio
On Apr 6, 8:10 pm, "Edward K Ream" <[EMAIL PROTECTED]> wrote: > - Completed ILeo: a bridge between IPython and Leo. > See http://webpages.charter.net/edreamleo/IPythonBridge.html Additional note: to use ILeo, you need a new IPython. Download the not- yet-blessed release candidate (I don't fores

Re: ILeo (IPython-Leo bridge); a marriage made in heaven?

2008-02-23 Thread Ville Vainio
On Feb 23, 10:54 pm, Ricardo Aráoz <[EMAIL PROTECTED]> wrote: > Are you part of Leo? This smells like a marketing scheme to me. Yes, Edward is part of Leo and I am part of IPython. In fact, most of my income comes from selling IPython T-shirts at the local flea market and I therefore have to reso

ILeo (IPython-Leo bridge); a marriage made in heaven?

2008-02-22 Thread Ville Vainio
Here is something cool that will rock your world (ok, excuse the slight hyperbole): Introduction The purpose of ILeo, or leo-ipython bridge, is being a two-way communication channel between Leo and IPython. The level of integration is much deeper than conventional integration in IDEs

ANN: IPython 0.8.2 released!

2007-11-30 Thread Ville Vainio
Hi all, The IPython team is happy to release version 0.8.2, with lots of new enhancements (especially for system shell use - it has never been a better time for switching to "pysh" or "ipython -p sh" as your system shell of choice), as well as many bug fixes. We hope you all enjoy it, and please

ANN: IPyKit, the standalone IPython prompt

2007-05-28 Thread Ville Vainio
Some of you might want to play with IPyKit, especially you need a swiss-army-knife Python prompt on a (win32) machine where you don't really want to install anything (python, pyreadline, ipython, PATH settings...). It's basically a py2exe'd "preconfigured" IPython. http://ipython.scipy.org/moin/I

IPython 0.7.3 upgrade notes

2006-12-20 Thread Ville Vainio
Something I forgot to emphasize in the announcement, knowing that not everyone reads the release notes - if you are upgrading from a previous version of IPython, you must either: - Delete your ~/ipython (or ~/_ipython) directory OR - Run %upgrade once IPython starts. -- http://mail.python.org/ma

IPython 0.7.3 is out

2006-12-20 Thread Ville Vainio
Hi all, The IPython team is happy to release version 0.7.3, with a lot of new enhancements, as well as many bug fixes (including full Python 2.5 support). We hope you all enjoy it, and please report any problems as usual. WHAT is IPython? 1. An interactive shell superior to Py

Re: IPython 0.7.3 upgrade notes

2006-12-20 Thread Ville Vainio
Ville Vainio wrote: > Something I forgot to emphasize in the announcement, knowing that not > everyone reads the release notes - if you are upgrading from a previous > version of IPython, you must either: > > - Delete your ~/ipython (or ~/_ipython) directory OR > - Run %up

Re: IPython 0.7.3 upgrade notes

2006-12-20 Thread Ville Vainio
Ville Vainio wrote: > Something I forgot to emphasize in the announcement, knowing that not > everyone reads the release notes - if you are upgrading from a previous > version of IPython, you must either: > > - Delete your ~/ipython (or ~/_ipython) directory OR > - Run %up

IPython 0.7.3 upgrade notes

2006-12-20 Thread Ville Vainio
Something I forgot to emphasize in the announcement, knowing that not everyone reads the release notes - if you are upgrading from a previous version of IPython, you must either: - Delete your ~/ipython (or ~/_ipython) directory OR - Run %upgrade once IPython starts. -- http://mail.python.org/ma

IPython 0.7.3 beta 2 is out!

2006-12-08 Thread Ville Vainio
Yes, next version of IPython is closing in on final release around the years end, with lots of new exiting features (full list TBD, but it *does* include proper python 2.5 support if that's what you've been waiting for). Get the 0.7.3 beta 2 it at http://projects.scipy.org/ipython/ipython/wiki/Re

IPython team needs a student for a google "Summer of Code" project.

2006-05-03 Thread Ville Vainio
This comes in a bit of a hurry (you only have time until next monday to sign up), but here's the deal: The next version of ipython (0.7.2, "out soon", pretty much done already) will include an extension for browsing and manipulating tabular data (e.g. file name, file size, permissions etc.) called

Re: list.clear() missing?!?

2006-04-14 Thread Ville Vainio
Duncan Booth wrote: > Looking in the 'obvious' place in the Tutorial, section 5.1 'More on > Lists' I found in the immediately following section 5.2 'The del > statement': I read the tutorial 6 years ago, and don't read it regularly. What's in the tutorial is not really important, what can be eas

Re: list.clear() missing?!?

2006-04-12 Thread Ville Vainio
Ville Vainio wrote: > Assigning to slices is much less important, and is something I always > never do (and hence forget). ALMOST never, of course. -- http://mail.python.org/mailman/listinfo/python-list

Re: list.clear() missing?!?

2006-04-12 Thread Ville Vainio
Raymond Hettinger wrote: > * easier to figure-out, look-up, and remember than either s[:]=[] or > del s[:] Easier is an understatement - it's something you figure out automatically. When I want to do something w/ an object, looking at its methods (via code completion) is the very first thing. >

Re: list.clear() missing?!?

2006-04-11 Thread Ville Vainio
John Salerno wrote: > Thanks guys, your explanations are really helpful. I think what had me > confused at first was my understanding of what L[:] does on either side > of the assignment operator. On the left, it just chooses those elements > and edits them in place; on the right, it makes a copy

Re: list.clear() missing?!?

2006-04-11 Thread Ville Vainio
Steven Bethard wrote: > If you feel really strongly about this though, you might consider > writing up a PEP. It's been contentious enough that there's not much > chance of getting a change without one. No strong feelings here, and I'm sure greater minds than me have already hashed this over suf

Re: list.clear() missing?!?

2006-04-11 Thread Ville Vainio
Fredrik Lundh wrote: > > I tried to clear a list today (which I do rather rarely, considering > > that just doing l = [] works most of the time) and was shocked, SHOCKED > > to notice that there is no clear() method. Dicts have it, sets have it, > > why do lists have to be second class citizens? >

list.clear() missing?!?

2006-04-11 Thread Ville Vainio
I tried to clear a list today (which I do rather rarely, considering that just doing l = [] works most of the time) and was shocked, SHOCKED to notice that there is no clear() method. Dicts have it, sets have it, why do lists have to be second class citizens? -- http://mail.python.org/mailman/lis

Re: How many web framework for python ?

2006-02-19 Thread Ville Vainio
Sybren Stuvel wrote: > Why forget it? I've written my own web framework > (http://www.unrealtower.org/) and it works great! It was a good Some reasons: - Waste. When you write your own framework, you are helping yourself. If you use an existing framework and possibly contribute patches to it, yo

Re: How many web framework for python ?

2006-02-18 Thread Ville Vainio
Bo Yang wrote: > There are very good web framework for java and ruby , > Is there one for python ? There are many good ones. > I want to write a web framework for python based on > mod_python as my course homework , could you give some > advise ? Implement yet another web framework? It needs to

Re: Evil, evil wxPython (and a glimmer of hope)

2006-02-17 Thread Ville Vainio
Torsten Bronger wrote: > Has Wax exceeded the critical mass so that one can be quite certain > that it will still be maintained, say, next year? (Sincere question > since I don't know.) I was a bit worried about this myself, but after browsing the source I have to say I'm not terribly so anymor

Re: Thoughts on Guido's ITC audio interview

2005-07-07 Thread Ville Vainio
t; What line of work is not supported in eclipse? C++ programming for Symbian OS. Editing the C++ code works, debugging doesn't, at least yet. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Thoughts on Guido's ITC audio interview

2005-07-01 Thread Ville Vainio
r editing if I Timothy> wished whilst still having everything readily available. Eclipse allows this as well. ctrl+m is maximize/unmaximize. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: *Python* Power Tools

2005-06-22 Thread Ville Vainio
could evolve gradually, and reach a useful stage (i.e. have several handy tools) quickly. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Loop until condition is true

2005-06-22 Thread Ville Vainio
the first place, given that everyone can identify the idiom immediately. It's 4 keystrokes less. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Dr. Dobb's Python-URL! - weekly Python news and links (Jun 7)

2005-06-08 Thread Ville Vainio
the interesting tidbits from the depths of 500-post threads where people can't be bothered to change the subject line... -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Python analog of Ruby on Rails?

2005-05-26 Thread Ville Vainio
#x27; Shane> I'm Christian and I think it's funny. ;-) Some background: Shane> http://scriptures.lds.org/rev/13/16-18#16 Shane> http://www.greaterthings.com/Word-Number/666HolyBible.htm Ah, it was *obvious* from the start that the placement of ASCII letters was

Re: Just remember that Python is sexy

2005-05-26 Thread Ville Vainio
this: "index" and "sex" both end with "ex", which Greg> is short for "exception". Or something about the use of index finger being an exception from the conventional strategy... -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Just remember that Python is sexy

2005-05-26 Thread Ville Vainio
nd you won't have anything to remember: Peter> 'foo bar baz'.find('spam') Peter> 'spanish inquisition'.index('parrot') But which one raises an exception, and which one returns -1? -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: first release of PyPy

2005-05-22 Thread Ville Vainio
Christian> RPython, a sub-language of Python that is implicitly Christian> defined by "simple and static enough to be compilable". Could it be possible to tag some modules in application code as RPython-compatible, making it possible to implement the speed critical par

Re: moving from c++ to python

2005-05-21 Thread Ville Vainio
n python. MyClass* c = new MyClass(12,13); is equal to c = MyClass(12,13) There is no equivalent to MyClass c(12,13); because it's not needed. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: first release of PyPy

2005-05-21 Thread Ville Vainio
>>>>> "Ville" == Ville Vainio <[EMAIL PROTECTED]> writes: Ville> This is not about PyPy but it might help: Ville> http://www.python.org/pycon/dc2004/papers/1/paper.pdf (It's about starkiller, sorry about the opaque url) -- Ville

Re: first release of PyPy

2005-05-21 Thread Ville Vainio
rations) to avoid dict lookups in method dispatch. This is not about PyPy but it might help: http://www.python.org/pycon/dc2004/papers/1/paper.pdf -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Is Python suitable for a huge, enterprise size app?

2005-05-19 Thread Ville Vainio
>>>>> "brian" == brian <[EMAIL PROTECTED]> writes: brian> to build expertise and confidence, etc. People are more brian> important than programming language. Or so you would think before writing sizeable software in C++. -- Ville Vaini

Re: Like Christ PBBUH Prayed

2005-05-17 Thread Ville Vainio
t; George> Maybe they know something we don't. The information is generally reserved for 34DEG pythonistas. All will be cleared for lower degree aspirants in due time. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: python-dev Summary for 2005-04-16 through 2005-04-30

2005-05-16 Thread Ville Vainio
2005-May/053702.html It's convincing, but I would still prefer to leave the decision of pulling the trigger on the foot for the implementor of the block function, with the recommendation that all exceptions are propagated. What happened to "we are all adults here"? I don't min

Re: python-dev Summary for 2005-04-16 through 2005-04-30

2005-05-16 Thread Ville Vainio
nly real reason for choosing Ruby over Python blown away... -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Ruby blocks finally coming to python? (was Re: python-dev Summary for 2005-04-16 through 2005-04-30

2005-05-16 Thread Ville Vainio
ony> and invoke it as something like:: Tony> block locking(lock): Tony> CODE -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Interactive shell for demonstration purposes

2005-05-11 Thread Ville Vainio
console window has a limited number of Brian> selectable fonts, it doesn't work terribly well. Hmm, do you consider the fonts in a console window unreadable? I've given a few presentations using ipython on win32 and it worked alright - but I suppose the projector quality is

Re: Solipsis: Python-powered Metaverse

2005-05-10 Thread Ville Vainio
of) are connected "directly" to the internet (in the sense that all ports are open). Blocking is reserved for the modem, just the way it should be... -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Difference between Python CGI applications and Php applications

2005-05-04 Thread Ville Vainio
and psp (python server pages) for a more straightforward conversion: http://www.onlamp.com/pub/a/python/2004/02/26/python_server_pages.html -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: BitKeeper for Python?

2005-05-02 Thread Ville Vainio
odeville, also written in Python. Or bazaar-ng, also written in python. Bruce> Codeville's said to be pretty usable. Ditto, through the repo format has not been stabilized yet. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Which IDE is recommended?

2005-04-29 Thread Ville Vainio
nd debugger are the most obvious ones. Eclipse itself is also quite a "feature". -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: large dictionary creation takes a LOT of time.

2005-04-29 Thread Ville Vainio
>>>>> "Kent" == Kent Johnson <[EMAIL PROTECTED]> writes: Kent> if frequency.has_key(word): Kent> frequency[word] += 1 Kent> else: Kent> frequency[word] = 1 This is a good place to use 'get' method of dict: frequency[word]

Re: Which IDE is recommended?

2005-04-28 Thread Ville Vainio
>>>>> "Brian" == Brian Beck <[EMAIL PROTECTED]> writes: Brian> Ville Vainio wrote: >> Perhaps you are just being impatient? >> >> Also, make sure that Preferences/pydev/code completion has >> "Autocomplete o

Re: Which IDE is recommended?

2005-04-28 Thread Ville Vainio
hing in your source file that trips up pydev? Whining at the pydev mailing list might work as well. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Which IDE is recommended?

2005-04-28 Thread Ville Vainio
#x27;ve used does it. This is Brian> more like semi-automatic code completion. It works like that for me. I type: import os os. And I get the list of completions. Perhaps you are just being impatient? Also, make sure that Preferences/pydev/code completion has "Autocomplete on '.&

Re: Which IDE is recommended?

2005-04-27 Thread Ville Vainio
>>>>> "pydev" == Brian Beck <[EMAIL PROTECTED]> writes: pydev> * PyDev isn't yet mature enough to make it practical for me What version? PyDev has increased in maturity quite a bit lately. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: names of methods, exported functions

2005-04-27 Thread Ville Vainio
re.UNICODEre.__name__ re.finditer re.subn re.LOCALE re.VERBOSEre.compilere.match re.template re.M re.X re.engine re.purge re.__class__ [~]|129> re. ISTR the completion can be added to plain old python prompt as well, through rlcompleter.

Re: Python internal design

2005-04-26 Thread Ville Vainio
esign. Emre> I wonder how these issues are implemented in Python are Emre> there any documents or articles about it, which I can read Emre> and get an idea. It's built around string lookup. obj.stuff() -> look up what object is associated with string 'stuff'

Re: What's do list comprehensions do that generator expressions don't?

2005-04-25 Thread Ville Vainio
t; in a list or a generator with () or []. Still, list comprehensions should be implemented in terms of genexps to get rid of the LC variable that is visible outside the scope of the LC. Jeremy> should be relatively simple), it's not worth breaking that Jeremy> code. Wel

Re: Python or PHP?

2005-04-24 Thread Ville Vainio
d library functions didn't raise them, the feature would not be worth much. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Python or PHP?

2005-04-24 Thread Ville Vainio
less punctuation to worry about, no error handling needed (exceptions take care of it automatically). I would also venture to guess that random (adult) Python programmers would be of higher skill level as far as programming in general goes (know more languages, have a "good taste"...). -- Ville V

Re: Object oriented storage with validation (was: Re: Caching compiled regexps across sessions (was Re: Regular Expressions - Python vs Perl))

2005-04-24 Thread Ville Vainio
of getting Ilpo> the regexps, but how and where to store the compiled data? Ilpo> Is there a way to put it to the byte code file? Do what you already did - dump the regexp cache to a separate file. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Python or PHP?

2005-04-23 Thread Ville Vainio
uring Leif> completeness. PHP isn't. +1 QOTW. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Caching compiled regexps across sessions (was Re: Regular Expressions - Python vs Perl)

2005-04-23 Thread Ville Vainio
x27;t you use external validation on the created xml? Validating it every time sounds like way too much like Javaic B&D to be fun anymore. Pickle should serve you well, and would probably remove about half of your code. "Do the simplest thing that could possibly work" and all that. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Regular Expressions - Python vs Perl

2005-04-22 Thread Ville Vainio
he regexps? I can't imagine you change more than, say, 10 of the regexps a day (compiling of which is an insignificant performance hit) and when you "ship" the script, you will freeze the regexps anyway. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Regular Expressions - Python vs Perl

2005-04-22 Thread Ville Vainio
s. One Ilpo> example is the xmlproc parser in PyXML, Read the source for sre.py, esp. _compile. The compiled regexps are cached, so when you invoke e.g. re.match(), it doesn't recompile the regexp. So this point is moot, and perl's approach is excessive special casing. -- Ville Vaini

Re: Nokia to speak at Python-UK next week

2005-04-18 Thread Ville Vainio
mp; nope. It would be easy-ish to get Python working on a console level on 9300/9500 if there was access to the source code... There's also an open source implementation of Python for UIQ (UI toolkit used by SonyEricsson) See http://www.mobilewhack.com/programming/python/ --

Re: templating system

2005-04-13 Thread Ville Vainio
never had a need It would be interesting to see benchmarks comparing different templating system. I suppose a web templating system like PSP (of mod_python) would be optimized for speed. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Programming Language for Systems Administrator

2005-04-13 Thread Ville Vainio
t Ouput. Have you tried the 'subprocess' module to see whether it solves your problems, new in 2.4? That said, I've never had the problems you describe with normal popen* calls either. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Programming Language for Systems Administrator

2005-04-13 Thread Ville Vainio
MSH passes data between beliavsky> the various commandlets as arbitrary objects. They clearly read my rant from last summer http://groups.google.com/groups?threadm=du7brj2mpg9.fsf%40mozart.cc.tut.fi ;-) -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

win32 readline maintenance (was Re: IPython - problem with...

2005-04-12 Thread Ville Vainio
27;t need to be "transferred" - just put up version control somewhere and we'll see what happens :-). In the meantime I would suggest win32 users to do as I do and use a different keyboard layout. US layout is better for programming anyway and you learn it in a day or two. Settings->

Re: IPython - problem with using US international keyboard input scheme on W2K

2005-04-12 Thread Ville Vainio
dinavian character (ÃÃ) on ipython console, luckily I never have to do that :-). -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Programming Language for Systems Administrator

2005-04-12 Thread Ville Vainio
tually bump into a problem where you need to be able to do bash scripting. There's the 'Unix romantic' movement that still thinks shell scripts are a good idea, but this is my .02EUR to point out that not everyone agrees with them. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: IPython - problem with using US international keyboard input scheme on W2K

2005-04-11 Thread Ville Vainio
nstead of " when Claudio> trying to input quotation marks? This has been reported previously - apparently it's a problem with Gary's readline module (or however it was called ;-), and hacking it solved the problem for someone. I suggest you search the ipython mailing list

Re: Best editor?

2005-04-06 Thread Ville Vainio
rev-expand to F4, jjl> and it seems even better than 'proper' completion (for jjl> reducing keystrokes, anyway). But does not work when you don't know/can't recall what methods are available for the object you are looking at. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Best editor?

2005-04-06 Thread Ville Vainio
>>>>> "caneff" == ChinStrap <[EMAIL PROTECTED]> writes: caneff> Anyone want to send me a configuration setup with Python caneff> in mind, and decent colors? http://www.emacswiki.org/cgi-bin/wiki/ColorTheme -- Ville Vainio http://tinyurl.com/2pr

Re: boring the reader to death (wasRe: Lambda: the Ultimate Design Flaw

2005-04-06 Thread Ville Vainio
>>>>> "Sunnan" == Sunnan <[EMAIL PROTECTED]> writes: Sunnan> Ville Vainio wrote: Sunnan> Also, Guido recently urged people to explicitly write Sunnan> recursions rather than to use reduce - which I thought was Sunnan> completely in

Re: Best editor?

2005-04-06 Thread Ville Vainio
arning unless you are an emacs user already. Emacs also looks so horrible in Linux that I tend to go for Kate when I'm at home. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: boring the reader to death (wasRe: Lambda: the Ultimate DesignFlaw

2005-04-06 Thread Ville Vainio
on list comprehensions and generator expressions. You'll see the terse side of Python (and genexps look kinda poetic too ;-). -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: boring the reader to death (wasRe: Lambda: the Ultimate Design Flaw

2005-04-06 Thread Ville Vainio
ut what a piece of code does. It's a code that you wish you could train a monkey to write for you while you go for lunch. Think C++ or Java. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Case-insensitive dict, non-destructive, fast, anyone?

2005-04-05 Thread Ville Vainio
e for 'keytransform' feature apart from the uses that would be better covered by hash/comparison hooks? It would be lovely to have something like this in the stdlib (or anywhere, for that matter). Think about the use cases for hashing via by os.path.normcase, str.lower... -- Ville Vaini

Re: Case-insensitive dict, non-destructive, fast, anyone?

2005-04-01 Thread Ville Vainio
>>>>> "Daniel" == Daniel Dittmar <[EMAIL PROTECTED]> writes: Daniel> Ville Vainio wrote: >> I need a dict (well, it would be optimal anyway) class that >> stores the keys as strings without coercing the case to upper >> or l

Case-insensitive dict, non-destructive, fast, anyone?

2005-04-01 Thread Ville Vainio
.keys() ['Hi','hoho'] Note that 'Hi' preserved the case. I imagine that 'Hi' and 'hi' would need to share the same hash value in order for the lookup to be fast. Anyone have a an implementation that I could use? Quick googling only produced implem

Re: itertools to iter transition (WAS: Pre-PEP: Dictionary accumulator methods)

2005-03-30 Thread Ville Vainio
t such operations should not be dumped into the builtin iter. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: itertools to iter transition (WAS: Pre-PEP: Dictionary accumulator methods)

2005-03-29 Thread Ville Vainio
e. I'd rather see a more modular and 'slimmer' Python, what with the advent of Python for S60 and other embedded uses. Perhaps what you need is 'from usefulstuff import *', with usefulstuff having os, sys, 'itertools as it', &c. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Why tuple with one item is no tuple

2005-03-29 Thread Ville Vainio
>>>>> "Ville" == Ville Vainio <[EMAIL PROTECTED]> writes: Ville> To me, nothing is more natural than "ab" + "cd" == Ville> "abcd". Also [1,2] + [3,4] == [1,2,3,4]. "Dot product" is Ville> not really to

Re: Why tuple with one item is no tuple

2005-03-29 Thread Ville Vainio
oncatenation (string Antoon> concatenation included) To me, nothing is more natural than "ab" + "cd" == "abcd". Also [1,2] + [3,4] == [1,2,3,4]. "Dot product" is not really too useful in real world (non-mathematical) apps. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: itertools to iter transition (WAS: Pre-PEP: Dictionary accumulator methods)

2005-03-29 Thread Ville Vainio
I don't really see the advantage in moving away from itertools. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Python for a 10-14 years old?

2005-03-24 Thread Ville Vainio
d feel they should be. (urgh, way too serious to be pythonic, but it's 5:14am here) -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Python for a 10-14 years old?

2005-03-24 Thread Ville Vainio
ke an OS than any other home computer till then. And Christos> man, wasn't 68k assembly a joy :) Linus Torvalds also bought Sinclair Ql back in the day - I was quite surprised to find out that it had a 32bit CPU (according to his autobiography). -- Ville Vainio http://tinyurl

Re: Suggestions for a Java programmer

2005-03-24 Thread Ville Vainio
es of Python. So a Java programmer, when confronted with a problem, should think "how can I solve this using lists, dicts and tuples?" (and perhaps also my new favourite, sets). Class-based solution should be chosen only after seeing that the problem can't be trivially sol

Re: IronPython 0.7 released!

2005-03-23 Thread Ville Vainio
>>>>> "Robin" == Robin Becker <[EMAIL PROTECTED]> writes: Robin> well that's nice, but I don't do blogs and certainly don't You don't need to "do" much - just go to planetpython.org -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: IronPython 0.7 released!

2005-03-23 Thread Ville Vainio
ose who were afraid the project is dead due to silence... -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Interface support?

2005-03-18 Thread Ville Vainio
ols.html, This (PyProtocols) seems to be the one with biggest momentum at the time being, so if you can't be bothered to perform an independent and balanced evaluation, go for PyProtocols :-). -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

REPOST: Re: Python becoming less Lisp-like

2005-03-17 Thread Ville Vainio
he real one would have the same problem. And who Torsten> knows how C# looks like in 10 years. http://c2.com/cgi/wiki?PythonVsRuby seems to suggest that Python has better Unicode support than Ruby. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

REPOST: Re: Python becoming less Lisp-like

2005-03-17 Thread Ville Vainio
ame name for all those little functions to avoid polluting the namespace. Choose 'L' if it gives you that cozy lambda-ish feel. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: I can do it in sed...

2005-03-17 Thread Ville Vainio
>>>>> "John" == John Machin <[EMAIL PROTECTED]> writes: John> You can get gnu Windows versions of awk sed and most other John> suchlike goodies off the net ... Yeah, google for 'unxutils'. Cygwin versions of these tools can be a headache so

Re: I can do it in sed...

2005-03-17 Thread Ville Vainio
Damjan> if line.endswith('end'): printing=0 No, it's still line.startswith('end'), not endswith. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Python becoming less Lisp-like

2005-03-17 Thread Ville Vainio
the documentation I've seen regarding these features mentions that the user probably doesn't need to know about them; this is especially true for metaclasses. -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

Re: Is Python like VB?

2005-03-16 Thread Ville Vainio
s of pyGTK as well. People coming from VB background probably also appreciate the ability to draw the UI in point&click style: http://gazpacho.sicem.biz/ http://wxglade.sourceforge.net/ Unfortunately these seem to still be a tad rough around the edges... -- Ville Vainio http://tinyurl.com/2prnb -- http://mail.python.org/mailman/listinfo/python-list

  1   2   >