I want to add jsonschema as a third-party python dependency of validate_base (we’ll have an announcement post about that soon) as part of DM-7935. I’m a bit unclear about our handling of python externals, and the Developer Guide page Distributing Third-Party Packages with EUPS doesn’t entirely fit my scenario.
First, it seems that there are two ways we handle python externals in the Stack:
- As TaP packages, like those described in Distributing Third-Party Packages with EUPS that contains the python package as a tar file.
- As an EUPS ‘pseudo package’ that merely checks that the package is installed. An example is https://github.com/lsst/astropy
- Are there other alternatives?
I think my preference is to go with #2 so we’re not replicating what PyPI does already. Is this a correct assumption?
Going with #2, the procedure would then be:
- Create a repo
https://github.com/lsst/jsonschema
and implement it like https://github.com/lsst/astropy. - RFC this jsonschema package. (I’m not 100% sure this is necessary as it will only a dependency of the lsst_qa top-level package; not
lsst_apps
orlsst_distrib
. Maybe @timj can advise.). - Publish the jsonschema package following https://developer.lsst.io/build-ci/third_party.html#distributing-the-package.
- Add the jsonschema package to lsstsw’s
repos.yaml
. - Add jsonschema to the conda package lists in https://github.com/lsst/lsstsw/tree/master/etc.
- Document the dependency in https://pipelines.lsst.io/install/newinstall.html:
pip install jsonschema==2.5.1
. - Declare the dependency in validate_base.
I think steps 5, 6 and 7 are what I’m most unsure of. Is anything else needed to ensure that the jsonschema
python package is installed for newinstall, lsstsw and conda stack users?
Alternatively, should a jsonschema eups pseudopackage actually run pip install setup.py
through its ups/eupspkg.cfg.sh
.
I’ll turn responses to this topic and a corrected procedure into improved Developer Guide documentation.