fixed locals handling in startup, tested path handling