fix python mode hooks - python source file isn't working