why are you caching the working directory in a static variable?