Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python call :: use sys.executable instead of python #39

Closed
EricDeveaud opened this issue Nov 6, 2019 · 1 comment
Closed

python call :: use sys.executable instead of python #39

EricDeveaud opened this issue Nov 6, 2019 · 1 comment

Comments

@EricDeveaud
Copy link

there is some python call in the mob-suite code written as

p = Popen(['python', ...] )
os.system('python'.... )

I suggest you replace verbatim python by sys.executable.
on some situations, users may have a python in their path different form the one scripts have been installed with
NB this is how we perform our installation on our cluster.

this may lead to a call to a different python version, python with different set of modules and so on.

sys.executable will ensure that you will use the same interpreter,

Eric

kbessonov1984 added a commit that referenced this issue Nov 6, 2019
…databases directory as issue #38. Also changed python calls to sys.executable as per issue #39
kbessonov1984 added a commit that referenced this issue Nov 7, 2019
String encoding issues on POSIX locale, ete3 initialization moved to `databases` folder (issue #38), version key addition (issue #35), fixed meta data section in `setup.py` (issue #40), added external python calls using `sys.executable` issue #39
@kbessonov1984
Copy link
Collaborator

Thank you, I've changed code to call python in a more safer way via sys.executable in mob_recon on line 148

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants