linux - Python console_script entry point runs as Python2 -


i have package sets entry point console_script , want console_script run python function/script python3

my package uses urllib.request module (python3).

running command (the console_script) gives python error request not being module, thats why i'm thinking executes script python2..


__main__.py

import urllib.request ...  ... urllib.request.urlretrieve(url, file_path, progress) ... 

error

importerror: no module named request 

python --version python 2.7.13  python3 --version python 3.5.4rc1 

console_script scripts executed using whatever version of python used install package, e.g., if installed package pip, pip2, python2 -m pip, or like, script run under python 2. either uninstall package , re-install python 3 or else use six ensure script work under both versions.


Comments

Popular posts from this blog

What is happening when Matlab is starting a "parallel pool"? -

angular - DownloadURL return null in below code -

php - Cannot override Laravel Spark authentication with own implementation -