Skip to content

Commit

Permalink
updating for pip 19
Browse files Browse the repository at this point in the history
  • Loading branch information
jonrkarr committed Mar 13, 2019
1 parent 43bc5fd commit c720a53
Show file tree
Hide file tree
Showing 9 changed files with 32 additions and 15 deletions.
18 changes: 11 additions & 7 deletions .circleci/config.yml
Expand Up @@ -16,22 +16,26 @@ jobs:
# Python 3 installation tasks
- run:
name: Install pkg_utils (Python 3)
command: pip3 install -U --process-dependency-links git+https://github.com/KarrLab/pkg_utils.git#egg=pkg_utils
command: pip3 install -U git+https://github.com/KarrLab/pkg_utils.git#egg=pkg_utils
- run:
name: Install karr_lab_build_utils (Python 3)
command: pip3 install -U --process-dependency-links git+https://github.com/KarrLab/karr_lab_build_utils.git#egg=karr_lab_build_utils[all]
command: |
pip3 install -U git+https://github.com/KarrLab/log.git#egg=log
pip3 install -U git+https://github.com/KarrLab/sphinxcontrib-googleanalytics.git#egg=sphinxcontrib_googleanalytics
pip3 install -U git+https://github.com/KarrLab/wc_utils.git#egg=wc_utils[all]
pip3 install -U git+https://github.com/KarrLab/karr_lab_build_utils.git#egg=karr_lab_build_utils[all]
- run:
name: Install package configuration files including credentials
command: karr_lab_build_utils3 download-install-package-config-files
- run:
name: Install and upgrade requirements (Python 3)
name: Setup Python environment
command: |
set +e
karr_lab_build_utils3 install-requirements
karr_lab_build_utils3 upgrade-karr-lab-packages
if [[ -f .circleci/requirements.txt ]]; then
pip3 install -U -r .circleci/requirements.txt
fi
- run:
name: Install package (Python 3)
command: pip3 install -U --process-dependency-links -e .[all]
command: pip3 install -U -e .[all]

# Save packages to cache
- save_cache:
Expand Down
5 changes: 5 additions & 0 deletions .circleci/requirements.txt
@@ -0,0 +1,5 @@
# third party forks
git+https://github.com/KarrLab/log.git#egg=log

# Karr Lab
git+https://github.com/KarrLab/wc_utils.git#egg=wc_utils
4 changes: 2 additions & 2 deletions Dockerfile
Expand Up @@ -3,8 +3,8 @@ FROM karrlab/wc_env_dependencies
# install and configure software and examples
RUN git clone https://github.com/KarrLab/wc_sandbox.git \
&& cd /root/wc_sandbox \
&& pip3.6 install --process-dependency-links -r requirements.txt \
&& pip3.6 install --process-dependency-links -e . \
&& pip3.6 install -r ./circleci/requirements.txt \
&& pip3.6 install -e . \
\
&& jupyter contrib nbextension install \
&& jupyter nbextensions_configurator disable \
Expand Down
4 changes: 3 additions & 1 deletion README.md
Expand Up @@ -27,7 +27,9 @@ WC-Sandbox is a collection of Jupyter notebooks for learning about whole-cell mo

* Install the latest revision from GitHub
```
pip install git+git://github.com/KarrLab/wc_sandbox#egg=wc_sandbox
pip install git+https://github.com/KarrLab/log.git#egg=log
pip install git+https://github.com/KarrLab/wc_utils.git#egg=wc_utils
pip install git+https://github.com/KarrLab/wc_sandbox.git#egg=wc_sandbox
```

## Examples, tutorial, and documentation
Expand Down
4 changes: 3 additions & 1 deletion docs/installation.rst
Expand Up @@ -18,4 +18,6 @@ Latest revision from GitHub
---------------------------
Run the following command to install the latest version from GitHub::

pip install git+git://github.com/KarrLab/wc_sandbox.git#egg=wc_sandbox
pip install git+https://github.com/KarrLab/log.git#egg=log
pip install git+https://github.com/KarrLab/wc_utils.git#egg=wc_utils
pip install git+https://github.com/KarrLab/wc_sandbox.git#egg=wc_sandbox
2 changes: 1 addition & 1 deletion docs/requirements.txt
Expand Up @@ -2,6 +2,6 @@ sphinx >= 1.8
sphinx_rtd_theme >= 0.4.2
sphinxcontrib_addmetahtml >= 0.1.1
sphinxcontrib_bibtex
git+https://github.com/KarrLab/sphinxcontrib-googleanalytics.git#egg=sphinxcontrib_googleanalytics-0.1.1 >= 0.1.1
sphinxcontrib_googleanalytics >= 0.1.1
sphinxcontrib_spelling
sphinxprettysearchresults
2 changes: 1 addition & 1 deletion requirements.txt
Expand Up @@ -11,4 +11,4 @@ configobj # configuration
cement # CLI
gitpython
setuptools # pkg_resources
git+https://github.com/KarrLab/wc_utils.git#egg=wc_utils-0.0.3 >= 0.0.3
wc_utils >= 0.0.3
2 changes: 1 addition & 1 deletion setup.py
Expand Up @@ -3,7 +3,7 @@
import pkg_utils
except ImportError:
import pip._internal
pip._internal.main(['install', '--process-dependency-links', 'git+https://github.com/KarrLab/pkg_utils.git#egg=pkg_utils'])
pip._internal.main(['install', 'pkg_utils'])
import pkg_utils
import os

Expand Down
6 changes: 5 additions & 1 deletion wc_sandbox/__main__.py
Expand Up @@ -68,7 +68,11 @@ def _default(self):
git.Repo.clone_from('https://github.com/KarrLab/{}.git'.format(package_id), package_path)

py_v = '{}.{}'.format(sys.version_info[0], sys.version_info[1])
cmd = ['pip' + py_v, 'install', '--process-dependency-links', '-e', package_path]

cmd = ['pip' + py_v, 'install', '-r', os.path.join(package_path, '.circleci', 'requirements.txt')]
subprocess.check_call(cmd)

cmd = ['pip' + py_v, 'install', '-e', package_path]
subprocess.check_call(cmd)

print('Installed packages:\n- {}'.format('\n- '.join(sorted(package_ids))))
Expand Down

0 comments on commit c720a53

Please sign in to comment.