I coincidentally found out that I cannot change the actual directory from within a python-code. My Test-Program is as follows:
from os import system
def sh(script):
system("bash -c '%s'" % script)
sh("cd /home")
sh("pwd")
The output of pwd is not /home, but the directory where the code above lives.
Can someone explain why this happens?