Flow based programming in python