Comment by Scarblac
10 months ago
When a module is first loaded, it's compiled to bytecode and then executed. Importing a non existing function will throw an error right away.
It's not a compilation error but it does feel like one, somewhat. It happens at more or less the same time.
Yes, that works if you do:
but if you do:
You get a run time error.
A lot of the time with Python you will be importing classes so it will be mostly run time errors.