Updated python version to use built-in cache
integrated changes from head
should probably gitignore the caches...