[vistrails-dev] [VisTrails] Use a top-level namespace package for VisTrails packages (#1002)

Remi Rampin notifications at github.com
Wed Feb 25 15:14:00 EST 2015

Historically, the 'codepath' of a VisTrails package has always been tied to the physical location of its code. Importing standard packages used `vistrails.packages.`, user packages from `~/.vistrails/userpackages` used `userpackages.`.

My goal with this PR is to put all of the packages under `vistrailspkg.`, to avoid having third-party packages being accessible from different names depending on where they are.

Python libs registering themselves as VisTrails packages using the pkg_resources "entry points" mechanism (7337e8e0), for example tej ([tej:a43e5b3a](https://github.com/remram44/tej/commit/a43e5b3a694d058b5baa59a20b88b24234181d86)), are fine: their codepath is fixed and known. I used a `vistrailspkg.` top-level namespace package there.

Another solution would be a new import mechanism that would use package identifiers, possibly with versions.
You can view, comment on, or merge this pull request online at:


-- Commit Summary --

  * Adds a top-level 'vistrailspkg' package
  * Rewrites 'vistrails.packages.xxx' imports
  * Magically makes vistrails.packages be vistrailspkg

-- File Changes --

    M setup.py (3)
    M vistrails/core/packagemanager.py (6)
    M vistrails/packages/__init__.py (10)
    A vistrailspkg/__init__.py (7)

-- Patch Links --


Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.vistrails.org/pipermail/vistrails-dev/attachments/20150225/21beb2a8/attachment.html>

More information about the vistrails-dev mailing list