Record Animation not working
Python scripts run blocking in Blender, which means Blender will wait and UI be locked until finished. You won't see an animation therefore, no matter if you use time.sleep() or not.

Use a frame change handler to register a callback function, that changes objects on every frame change (before or after):

http://www.blender.org/documentation/blender_python_api_2_70_release/bpy.app.handlers.html