I am not familiar with the nose, but I am sure that this means that the “import is safe” is that importing the module will simply determine things, and not leave and run the material.
The idea would be that if the .py file is intended to be executed as a script, then its functionality will be triggered when the module's scope code is executed. This may be protected from import with the __name__ == '__main__'
trick, but it may not be. If this is not the case, importing will probably do the same thing as in the case of the script when called without arguments, which in some cases can be bad.
So, you can directly say that there are no such executable scripts that can be dangerous to import by passing the --exe
flag, or you can clear the executable permission from your scripts.
source share