Knowledge Base/EPD (Enthought Python Distribution)/Updating packages in EPD

Using enpkg to update Canopy/EPD packages

Jonathan March
posted this on November 18, 2012 12:11

(updated October 25, 2013)
   
You can use the enpkg utility to download, install, and update any packages that are licensed for your Canopy/EPD account. A Canopy/EPD Academic, Basic, or higher subscription covers all Canopy/EPD packages. A registered Enthought account (Canopy Express, EPD Free) covers updates only for the core scientific Python packages.
  

If you are using Canopy:

  • Be sure that your PATH is set to Canopy User Python, as described in this article, and not to Canopy's initially installed Python, which is for Canopy's internal use only. 
  • At present, enpkg does not understand virtual environments, so will not be aware that the packages Qt, PySide and MKL were installed in Canopy Core and inherited by the Canopy User Python environment. Therefore one might be tempted to install them with enpkg. There is usually no need to do so (except to change versions.)
  • Also because enpkg is venv-blind, if you do an update of one of the originally installed packages (whether it was from the Express or the Full installer), and you subsequently ask enpkg to revert to the originally installed version, then it won't be aware that the original version is available through Canopy Core, so will download its own copy of the same egg file and re-install from that.
From a terminal (e.g. cmd or bash) prompt, update the EPD installer and see an overview of the enpkg commands:
$ enpkg enstaller
$ enpkg --help 

Enter your email and EPD password. (You will be prompted for each of them after the following command):
$ enpkg --userpass
Display all available versions (and installation status, marked by asterisk) of all packages that match a case-insensitive string:
$ enpkg --search pand

Please note that packages marked "pypi" are part of our subscriber-only "PyPI" mirror repo of about 11000 "as-is" (untested and unsupported) community packages.

Update whatever packages you like, to the most recent versions in the online EPD repository:
$ enpkg ipython
$ enpkg pandas
$ enpkg matplotlib
$ enpkg scipy

Or for the most recent version of all already-installed packages (only from enpkg version 4.6 or higher):
$ enpkg --update-all

 

Display available updates of already-installed packages:
$ enpkg --whats-new

 

 Display the history (with versions) of all package installations and updates done with enpkg (or egginst) in this Python installation.

$ enpkg --log

 

Install an exact version-build of a particular package (especially useful for rollback):
$ enpkg numpy 1.6.1-5

  

If you are using EPD (not Canopy) on OSX, you should precede these commands by "sudo ".
.

Please do not enter support requests in article comments

Please use article comments for suggestions to improve the article. For individual support requests, please follow these guidelines.

 

Comments

User photo
Saeed Assadi

works perfectly with OS 10.8.2

February 14, 2013 12:05
User photo
Niko Heeren

maybe this is obvious for most people, but I had to locate enpkg on my mac first. so in my case the was:

sudo /Library/Frameworks/EPD64.framework/Versions/7.3/bin/enpkg enstaller

March 05, 2013 07:59
User photo
Niko Heeren

some more info: I am using 10.8.2 and a limited user account. so in terminal I needed to login as admin first and locate the path.

March 05, 2013 08:04
User photo
Jonathan March
Enthought

Thanks for the feedback, Niko. Almost all individual EPD users have full admin access; the EPD installation includes the following lines in ~/.bash_profile:

PATH="/Library/Frameworks/Python.framework/Versions/Current/bin:${PATH}"
export PATH

or

PATH="/Library/Frameworks/EPD64.framework/Versions/Current/bin:${PATH}"
export PATH

This means that the user normally does not need to be aware of the details of the EPD installation location.

It sounds as if you installed EPD as an admin, so that admin user's PATH would have been set correctly, but you are running it as another user. It would probably be most convenient for you to make the above modification to your limited user account's ~/.bash_profile .

FYI the next version of EPD, now in beta, will not require admin rights at all; it would always be installed from the account of the intended user.

March 05, 2013 12:46
User photo
Niko Heeren

Hi Jonathan. Thank you for the nice hint and the info. You probably meant I should do the change in the administrator account ;)

On my limited account the path is properly set, but I cannot sudo.

March 07, 2013 16:24
User photo
Jonathan March
Enthought

Please do not enter support requests in article comments

 

Please use article comments for suggestions to improve the article. For individual support requests, please see:

https://support.enthought.com/entries/22415022-Using-enpkg-to-update-EPD-packages

April 29, 2013 12:14
User photo
Vladimir Filipovic
Winton Capital
Proposal: how about also mentioning "enpkg --whats-new" (an option I've found very useful when first getting used to EPD) and "enpkg $PKG-$VERSION" (not mentioned in --help but critical when you find you really need to revert to an older version).
May 30, 2013 06:31
User photo
Peter Durr

Hi.

what is the exact format for   --userpass?

can you give an example?

thanks

September 30, 2013 19:32
User photo
Jonathan March
Enthought

@Peter: I tweaked the wording, hopefully to be even more explicit:

"Enter your email and EPD password. (You will be prompted for each of them after the following command):"
September 30, 2013 20:19
User photo
Jeroen Hofman

Hi,

 

I try to install cython using enpkg using:

enpkg cython  or 


enpkg cython 0.14

 

However I just get : 

Versions for package 'cython' are:
0.13 (no subscription), 0.14 (no subscription), 0.14.1 (no
subscription), 0.15 (no subscription), 0.15.1 (no subscription), 0.16
(no subscription), 0.19.1 (no subscription)

 

Am I doing something wrong?

 

Thanks

October 10, 2013 04:17
User photo
Jonathan March
Enthought

@Jeroen: Please read the entire article above. One of the following applies:

1) You don't have an Enthought account, at least not on this email address. See first paragraph.

2) You didn't log in using the "--userpass" option. See middle of the article.

3) You are not an Enthought subscriber (Academic, Basic, or higher.) At present, Cython is not a free package. See the link in the first paragraph.

 

October 10, 2013 20:25