ANN: Kamaelia 0.2.0 released!

Michael Sparks ms at cerenity.org
Wed Aug 3 18:07:40 EDT 2005


Tim Golden wrote:
> I just wanted to say that I find the ideas behind Kamaelia
> interesting, and I only wish I had an application for it!
> Because I'm not especially into media-streaming, I'm more
> interested in it from the point of view of the generator-based
> architecture.

It's nice to know that people find it interesting even without a direct
need. (Indeed I suspect this is the case with many open source projects.)

One thing we are learning as we go along is how to use generators to
refactor out commonly used code out of loops like this. One example is
status updating:

import time
def long_running_thing(foo):
   t = time.time()pplication for it!
> Because I'm not especially into media-streaming, I'm more
> interested in it from the point of view of the generator-based
> architecture.

It's nice to know that people find it interesting even without a direct
need. (Indeed I suspect this is the case with many open source projects.)

One thing we are learning as we go along is how to use generators to
refactor out commonly used code out of loops like this. One example is
status updating:

import time
def long_running_thing(foo):
   t = time.time()
   while running:
       << do something long running>>
      if time.time() - t > update_interval:
         print update_message

An alternative to this is this:

def updater(interval, message):
   t = time.time():
   while 1:
      if time.time() - t > interval:
         print message

def long_running_thing(foo):
   myUpdater = updater(5, "Still running")
   while running:
       << do something long running>>
       myUpdater.next()

You can do similar things for frame rates and so on. Obviously in our system
we generally go one step further and translate the resulting generators into
components, but sometimes simple conversion to generators alone
can make the code much clearer.

Tim Golden wrote:
> What prompted me to write now was in appreciation of Michael's
> taking the effort to recast his words into a form which might
> well be understood better by others (including me) when he
> might well have simply huffed a bit and told the other poster
> to read the words on the site and stop complaining about the HTML!

I tend to generally think that for each poster to a newsgroup there's often
several lurkers who share the same opinion, and given text is a very harsh
medium, I try to make allowances for that. 

Answering questions can sometimes also help others to assist with
documentation patches of course. Technical writing not necessarily being
the same skill set as code writing or architecture design after all :-)

I must admit I do remember the earlier days of usenet when people would ask
a question, get several answers, and the original poster would summarise
the responses (something that doesn't happen as often these days
unfortunately, possibly due to services like google news making it easier
to go back and see the discussion).

phil hunt wrote:
> (And on a more general level to improve the average quality of 
> documentation for open source projects. Something which is bvery 
> often deficient.)

You have to remember as well that most open source projects rely on
volunteers, and anyone can write docs. If you want to improve the average
quality of docs for open source projects there is only one way to do this -
to be prepared to write the documentation yourself or pay someone to do
it. (In our case documentation is driven by internal need, which doesn't
always match the needs of people externally. You might not've seen the
white paper giving a detailed overview of the project from a technical
perspective here: http://tinyurl.com/8543e)

Tim Golden wrote:
> Thanks, Michael. Hope the project continues apace and if I
> can ever find a need for it, I'll know where to look.

Thanks for your kind words.

Best Regards,


Michael.




More information about the Python-list mailing list