I think, there´s nothing wrong with your code. But you should not put your main script (with the path instruction) into the code subfolder ...