Running a python script form the editor, divisions like
1/8 are true division; returning
However, If I create a module.py and import that for use in my main script; I get the old floor division behaviour where
0 This can be corrected by
from __future__ import division in my modules, but it seems a setup that is error prone.
Is this a bug or by design, and furthermore how to make sure imported modules behave as the main module?
What additional future behavior should I import to make sure all python scripts and modules behave equally regardless of them being main modules or imported ones?