Jump to content

Best practice for sharing workflows containing external (Python) dependencies


Recommended Posts

Hi there!

 

I've created a workflow that I want to share with my team, the workflow includes a Python script, which in turn has a dependency on a 3rd party library (the wonderful Requests[1]).

 

Are there any best practices around sharing this workflow with my team, whilst easing friction around the third party dependency? For example, currently I'm advocating dropping down to the command line and installing the Python dependency globally, ideally I'd like to avoid this, if at all possible.

 

Appreciate any pointers.

 

Kind regards!

Steve

 

 

[1] http://docs.python-requests.org/

Link to comment
You bundle the dependency with your workflow. End of discussion, basically.
 
cd to your workflow in a shell and run: pip install --target . requests
 

 

Asking users to install libraries is a PITA, and is very likely to cause problems down the line as Python doesn't support versioned libraries. Anything that can't be bundled probably has C extensions that need compiling, which is a world of hurt for the person supporting that.
Edited by deanishe
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...