Tuesday, January 6, 2009

user interfaces and criticism

Be warned, this is not serious stuff !!

I happen to do user interface development most of the time. It so happens that I am never able to do something which satisfies everybody. At best I am able to do an OK job. I did get to learn some interesting things over the years.
No matter how much effort one puts in user interface development, its never enough.
Its much much easier to find out issues in user interfaces than to implement solutions which take care of them properly. So just relax.
Its much more comfortable to be in the role of a critic than in the role of implementer. So try hard to get into such a role.
If you don't like the criticism you get, just sit back and relax. Don't reply back. Just ignore it and chill.
You will not like the user interface you have done if you look back at it after a few weeks or few months time. Don't try to improve it!! Its a never ending vicious circle.

Sunday, December 7, 2008

Mobicules

My long-time friends Niraj and Munish have started up a new company Mobicules. The company works in the areas of Web 2.0, social networking applications and related areas. They have been in operation for about a year now and have been doing well.
Both of them worked for Mentor (EDA) for about 5 years.
The company website is http://www.mobicules.com/.

Wednesday, November 5, 2008

Zope 3 Views as multi-adapters

This diagram shows how Zope Views are implemented as multi-adapters. Student is a content class which implements IStudent interface. HTTPRequest objects are created when an HTTP request (either through Web browsers, or through XML-RPC calls) is made. StudentView is an adapter which adapts a Student object along with an HTTPRequest object and implements IBrowserView interface.

The diagram is not accurate reflection of design of browser views in Zope. It is just for demonstration of the idea of multi-adapters.
Posted by Picasa

Sunday, September 28, 2008

Cron in Python

Cron jobs are traditional time based scheduling service on Unix platforms. For an introduction to cron jobs, go to: http://en.wikipedia.org/wiki/Crontab

At times, different software solutions may need to incorporate cron like functionality. I ended up doing the same recently. As usual, I first tried to find out if there are any existing implementations of cron available so that I do not have to re-invent the wheel again. I was looking for a Python based implementation and found the following: http://sourceforge.net/projects/pycron/ (Python Cron, Great Cron for Windows).

Although the title mentions Windows but the implementation can work on any Python based environment. The software is GPL licensed. Its a small and simple implementation of Cron in Python. The solution is easy to read and understand. It helped me understand some of the intricacies of cron implementation (like matching the cron table information with current time, taking care of system clock issues, etc.).

The algorithm is based on the initial simple implementation of cron by Brian Kernighan.
  1. Read the cron file
  2. Determine if any commands are to be run at the current date and time and if so, run them.
  3. Sleep for one minute
  4. Repeat from step 1.

Friday, August 15, 2008

Unicode Email in Python

Unicode email in Python requires quite good amount of care.

Read http://mg.pov.lt/blog/unicode-emails-in-python to know about it more.