converted to using Flask.
cleaning up.