Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Installing Python packages behind a proxy

rmelchiotti
7 - Meteor

Hi all,

I am trying to install python packages using the Python tool in the newest version of Alteryx but I am struggling. My current Alteryx installation is 2019.1 non-admin.

Since our internet connection is behind a proxy I selected the option Enable Proxy Credentials. The download tool works correctly but when I try to install packages using Package.installPackages I get the following error:

 

Collecting imblearn Retrying (Retry(total=4, connect=None, read=None, redirect=None)) after connection broken by 'ProtocolError('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None))': /simple/imblearn/

 

I get the same error regardless of what package I select.

 

Does anyone know why this is happening and how I can fix it?

 

Thanks a lot in advance

6 REPLIES 6
MichalM
Alteryx
Alteryx

Hi @rmelchiotti 

 

It sounds like your proxy may be blocking the resource we're trying to access. Could you please let me know what packages you want to install?

 

Thanks

Michal 

rmelchiotti
7 - Meteor

I was pretty sure it was a proxy issue but did not know how to fix it. In pip you can specify the proxy address and credentials but I don't know how to do it with package.installPackages.

The list of packages I need is pretty long: things like imblearn, keras, tensorflow, nltk, gensim, spacy, shap, sklearn.

MichalM
Alteryx
Alteryx

Do you want to try with the below?

 

Alteryx.installPackages(package="myPackage",install_type="install --proxy http://user:password@my_proxy_server:port")
rmelchiotti
7 - Meteor

Thanks a lot, that seems to work.

Wish there was another option to do this though, having a corporate password in clear embedded in a workflow is quite high risky.

MichalM
Alteryx
Alteryx

@rmelchiotti, I do appreciate this is not ideal.

You could potentially encrypt the workflow or embed the python tool into a macro which you can encrypt to keep the password safe. Here's how.

rmelchiotti
7 - Meteor

That is a good idea, thanks for the tip.

Labels