The generated finalize.py is marked as executable, when its file is created.
Here, we add a header such that one's shell know what to do with the file.
I've added python3, instead of a more classic /usr/bin/python3, to let whatever python3 pick it up.