I’ve just found a very interesting framework designed for Python/AJAX developers.
It’s called Kinetic Style Sheets, or KSS for short, and it’s goal is to use CSS with some additional syntax to pass marshalled data from server back to the client to manipulate the DOM without using a single line of JavaScript (most of the times).

Apparently it’s included in PLONE 3.0, a new version of framework I’ve used some time back, but due to my migration to lighter frameworks (TurboGears/Django) existence of KSS had evaded my attention until now.
“So what’s so hot about Kinetic Style Sheets?” you may ask “Does it move things?”… Well pretty much :) But that’s not the killer feat.

It’s designed for Python developers who wish to keep their nose in Python code as much as possible avoiding hairy JavaScript(browser) world.

It’s also designed not to break compatibility with JavaScript-disabled browsers.

Well that’s that for wetting appetite… It’s time to get a bite of this framework, and then I’ll be back with more thoughts.

Python [Show Plain Code]:
  1. import string
  2. from random import Random
  3.  
  4. newpasswd = .join( Random().sample( string.letters + string.digits, 12) )

It may be not so obvious at first that when you override save() in models to change something in a related object (ie via ForeignKey) you have to explicitly call save() on that related object.

Python [Show Plain Code]:
  1. class FirstObject(models.Model):
  2.    related_object = models.ForeignKey("SecondObject")
  3.    def save(self):
  4.       self.related_object.counter = self.related_object + 1
  5.       self.related_object.save()
  6.       super(FirstObject, self).save()
  7.  
  8. class SecondObject(models.Model):
  9.    counter = models.IntegerField(default=0)

And here I am again in Paris :)
I didn’t have much time yesterday to sniff around the expo, just walked by near it, but still I’ve took this footage of an interesting motorbike.

Today I hope to generate 1-2hrs to visit the expo. Especially because it’s just next door to where I work right now ;)