Skip to content

Commit

Permalink
Update development dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
Sterling Paramore committed Apr 23, 2019
1 parent c03ae66 commit 018a3db
Show file tree
Hide file tree
Showing 5 changed files with 75 additions and 86 deletions.
20 changes: 7 additions & 13 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
FROM ubuntu:14.04
FROM ubuntu:16.04

# Miniconda (w/ Python 3.6)
RUN apt-get update && apt-get install -y\
wget \
bzip2 \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

ENV CONDA_DIR /opt/conda
ENV PATH $CONDA_DIR/bin:$PATH
ENV MINICONDA_VERSION 4.5.4
Expand All @@ -21,19 +23,12 @@ RUN cd /tmp && \
conda install -y python=3.6.5 && \
conda clean -tipsy

# JAVA 8
RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install -y software-properties-common \
&& add-apt-repository ppa:webupd8team/java -y \
&& apt-get update \
&& echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections \
&& apt-get install -y oracle-java8-installer \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

# App-specific packages
RUN apt-get update && apt-get install -y \
postgresql-client \
libpq-dev \
gcc \
openjdk-8-jdk \
graphviz \
postgresql-client \
bash-completion \
Expand All @@ -58,7 +53,6 @@ ENV PYTHONUNBUFFERED 1
WORKDIR /app
COPY ./requirements/all.txt requirements/all.txt
RUN pip install --upgrade pip
RUN pip install pip-tools invoke && rm -rf /root/.cache
RUN pip install --ignore-installed -r requirements/all.txt && rm -rf /root/.cache

# Configure Jupyterlab
Expand Down
41 changes: 21 additions & 20 deletions requirements/all.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@
# This file is autogenerated by pip-compile
# To update, run:
#
# pip-compile requirements/all.in
# pip-compile -U requirements/all.in
#
alabaster==0.7.12 # via sphinx
appnope==0.1.0 # via ipython
astroid==2.2.5 # via pylint
atomicwrites==1.3.0 # via pytest
attrs==19.1.0 # via jsonschema, pytest
Expand All @@ -13,13 +14,13 @@ backcall==0.1.0 # via ipython
bleach==3.1.0 # via nbconvert
certifi==2019.3.9 # via requests
chardet==3.0.4 # via requests
dask==1.1.4
dask==1.2.0
decorator==4.4.0 # via ipython, traitlets
defusedxml==0.5.0 # via nbconvert
defusedxml==0.6.0 # via nbconvert
docutils==0.14 # via sphinx
entrypoints==0.3 # via nbconvert
factory-boy==2.11.1
faker==1.0.4
faker==1.0.5
graphviz==0.10.1
idna==2.8 # via requests
imagesize==1.1.0 # via sphinx
Expand All @@ -28,9 +29,9 @@ ipykernel==5.1.0 # via ipywidgets, jupyter, jupyter-console, notebook,
ipython-genutils==0.2.0 # via nbformat, notebook, qtconsole, traitlets
ipython==7.4.0 # via ipykernel, ipywidgets, jupyter-console
ipywidgets==7.4.2 # via jupyter
isort==4.3.16 # via pylint
isort==4.3.17 # via pylint
jedi==0.13.3 # via ipython
jinja2==2.10 # via nbconvert, notebook, sphinx
jinja2==2.10.1 # via nbconvert, notebook, sphinx
jsonschema==3.0.1 # via jupyterlab-server, nbformat
jupyter-client==5.2.4 # via ipykernel, jupyter-console, notebook, qtconsole
jupyter-console==6.0.0 # via jupyter
Expand All @@ -45,53 +46,53 @@ mistune==0.8.4 # via nbconvert
more-itertools==7.0.0 # via pytest
nbconvert==5.4.1 # via jupyter, notebook
nbformat==4.4.0 # via ipywidgets, nbconvert, notebook
notebook==5.7.7 # via jupyter, jupyterlab, jupyterlab-server, widgetsnbextension
numpy==1.16.2 # via pandas
notebook==5.7.8 # via jupyter, jupyterlab, jupyterlab-server, widgetsnbextension
numpy==1.16.3 # via pandas
packaging==19.0 # via sphinx
pandas-mapper==0.1.2
pandas==0.24.2
pandocfilters==1.4.2 # via nbconvert
parso==0.3.4 # via jedi
pexpect==4.6.0 # via ipython
parso==0.4.0 # via jedi
pexpect==4.7.0 # via ipython
pickleshare==0.7.5 # via ipython
pluggy==0.9.0 # via pytest
prometheus-client==0.6.0 # via notebook
prompt-toolkit==2.0.9 # via ipython, jupyter-console
psycopg2==2.7.7
psycopg2==2.8.2
ptyprocess==0.6.0 # via pexpect, terminado
py4j==0.10.7 # via pyspark
py==1.8.0 # via pytest
pygments==2.3.1 # via ipython, jupyter-console, nbconvert, qtconsole, sphinx
pylint==2.3.1
pyparsing==2.3.1 # via packaging
pyparsing==2.4.0 # via packaging
pyrsistent==0.14.11 # via jsonschema
pyspark==2.4.0
pytest==4.3.1
pytest==4.4.1
python-dateutil==2.8.0 # via faker, jupyter-client, pandas
pytz==2018.9 # via babel, pandas
pytz==2019.1 # via babel, pandas
pyzmq==18.0.1 # via jupyter-client, notebook
qtconsole==4.4.3 # via jupyter
requests==2.21.0 # via sphinx
send2trash==1.5.0 # via notebook
six==1.12.0 # via astroid, bleach, faker, jsonschema, packaging, prompt-toolkit, pyrsistent, pytest, python-dateutil, traitlets
snowballstemmer==1.2.1 # via sphinx
sphinx-rtd-theme==0.4.3
sphinx==2.0.0
sphinx==2.0.1
sphinxcontrib-applehelp==1.0.1 # via sphinx
sphinxcontrib-devhelp==1.0.1 # via sphinx
sphinxcontrib-htmlhelp==1.0.1 # via sphinx
sphinxcontrib-htmlhelp==1.0.2 # via sphinx
sphinxcontrib-jsmath==1.0.1 # via sphinx
sphinxcontrib-qthelp==1.0.2 # via sphinx
sphinxcontrib-serializinghtml==1.1.1 # via sphinx
sqlalchemy==1.3.1
sphinxcontrib-serializinghtml==1.1.3 # via sphinx
sqlalchemy==1.3.3
tabulate==0.8.3
terminado==0.8.2 # via notebook
testpath==0.4.2 # via nbconvert
text-unidecode==1.2 # via faker
tornado==6.0.2 # via ipykernel, jupyter-client, notebook, terminado
traitlets==4.3.2 # via ipykernel, ipython, ipywidgets, jupyter-client, jupyter-core, nbconvert, nbformat, notebook, qtconsole
typed-ast==1.3.1 # via astroid
urllib3==1.24.1 # via requests
typed-ast==1.3.4 # via astroid
urllib3==1.24.2 # via requests
wcwidth==0.1.7 # via prompt-toolkit
webencodings==0.5.1 # via bleach
widgetsnbextension==3.4.2 # via ipywidgets
Expand Down
31 changes: 16 additions & 15 deletions requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,29 @@
# This file is autogenerated by pip-compile
# To update, run:
#
# pip-compile requirements/base.in
# pip-compile -U requirements/base.in
#
appnope==0.1.0 # via ipython
astroid==2.2.5 # via pylint
atomicwrites==1.3.0 # via pytest
attrs==19.1.0 # via jsonschema, pytest
backcall==0.1.0 # via ipython
bleach==3.1.0 # via nbconvert
dask==1.1.4
dask==1.2.0
decorator==4.4.0 # via ipython, traitlets
defusedxml==0.5.0 # via nbconvert
defusedxml==0.6.0 # via nbconvert
entrypoints==0.3 # via nbconvert
factory-boy==2.11.1
faker==1.0.4
faker==1.0.5
graphviz==0.10.1
invoke==1.2.0
ipykernel==5.1.0 # via ipywidgets, jupyter, jupyter-console, notebook, qtconsole
ipython-genutils==0.2.0 # via nbformat, notebook, qtconsole, traitlets
ipython==7.4.0 # via ipykernel, ipywidgets, jupyter-console
ipywidgets==7.4.2 # via jupyter
isort==4.3.16 # via pylint
isort==4.3.17 # via pylint
jedi==0.13.3 # via ipython
jinja2==2.10 # via nbconvert, notebook
jinja2==2.10.1 # via nbconvert, notebook
jsonschema==3.0.1 # via jupyterlab-server, nbformat
jupyter-client==5.2.4 # via ipykernel, jupyter-console, notebook, qtconsole
jupyter-console==6.0.0 # via jupyter
Expand All @@ -38,38 +39,38 @@ mistune==0.8.4 # via nbconvert
more-itertools==7.0.0 # via pytest
nbconvert==5.4.1 # via jupyter, notebook
nbformat==4.4.0 # via ipywidgets, nbconvert, notebook
notebook==5.7.7 # via jupyter, jupyterlab, jupyterlab-server, widgetsnbextension
numpy==1.16.2 # via pandas
notebook==5.7.8 # via jupyter, jupyterlab, jupyterlab-server, widgetsnbextension
numpy==1.16.3 # via pandas
pandas-mapper==0.1.2
pandas==0.24.2
pandocfilters==1.4.2 # via nbconvert
parso==0.3.4 # via jedi
pexpect==4.6.0 # via ipython
parso==0.4.0 # via jedi
pexpect==4.7.0 # via ipython
pickleshare==0.7.5 # via ipython
pluggy==0.9.0 # via pytest
prometheus-client==0.6.0 # via notebook
prompt-toolkit==2.0.9 # via ipython, jupyter-console
psycopg2==2.7.7
psycopg2==2.8.2
ptyprocess==0.6.0 # via pexpect, terminado
py==1.8.0 # via pytest
pygments==2.3.1 # via ipython, jupyter-console, nbconvert, qtconsole
pylint==2.3.1
pyrsistent==0.14.11 # via jsonschema
pytest==4.3.1
pytest==4.4.1
python-dateutil==2.8.0 # via faker, jupyter-client, pandas
pytz==2018.9 # via pandas
pytz==2019.1 # via pandas
pyzmq==18.0.1 # via jupyter-client, notebook
qtconsole==4.4.3 # via jupyter
send2trash==1.5.0 # via notebook
six==1.12.0 # via astroid, bleach, faker, jsonschema, prompt-toolkit, pyrsistent, pytest, python-dateutil, traitlets
sqlalchemy==1.3.1
sqlalchemy==1.3.3
tabulate==0.8.3
terminado==0.8.2 # via notebook
testpath==0.4.2 # via nbconvert
text-unidecode==1.2 # via faker
tornado==6.0.2 # via ipykernel, jupyter-client, notebook, terminado
traitlets==4.3.2 # via ipykernel, ipython, ipywidgets, jupyter-client, jupyter-core, nbconvert, nbformat, notebook, qtconsole
typed-ast==1.3.1 # via astroid
typed-ast==1.3.4 # via astroid
wcwidth==0.1.7 # via prompt-toolkit
webencodings==0.5.1 # via bleach
widgetsnbextension==3.4.2 # via ipywidgets
Expand Down
41 changes: 21 additions & 20 deletions requirements/doc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@
# This file is autogenerated by pip-compile
# To update, run:
#
# pip-compile requirements/doc.in
# pip-compile -U requirements/doc.in
#
alabaster==0.7.12 # via sphinx
appnope==0.1.0 # via ipython
astroid==2.2.5 # via pylint
atomicwrites==1.3.0 # via pytest
attrs==19.1.0 # via jsonschema, pytest
Expand All @@ -13,13 +14,13 @@ backcall==0.1.0 # via ipython
bleach==3.1.0 # via nbconvert
certifi==2019.3.9 # via requests
chardet==3.0.4 # via requests
dask==1.1.4
dask==1.2.0
decorator==4.4.0 # via ipython, traitlets
defusedxml==0.5.0 # via nbconvert
defusedxml==0.6.0 # via nbconvert
docutils==0.14 # via sphinx
entrypoints==0.3 # via nbconvert
factory-boy==2.11.1
faker==1.0.4
faker==1.0.5
graphviz==0.10.1
idna==2.8 # via requests
imagesize==1.1.0 # via sphinx
Expand All @@ -28,9 +29,9 @@ ipykernel==5.1.0 # via ipywidgets, jupyter, jupyter-console, notebook,
ipython-genutils==0.2.0 # via nbformat, notebook, qtconsole, traitlets
ipython==7.4.0 # via ipykernel, ipywidgets, jupyter-console
ipywidgets==7.4.2 # via jupyter
isort==4.3.16 # via pylint
isort==4.3.17 # via pylint
jedi==0.13.3 # via ipython
jinja2==2.10 # via nbconvert, notebook, sphinx
jinja2==2.10.1 # via nbconvert, notebook, sphinx
jsonschema==3.0.1 # via jupyterlab-server, nbformat
jupyter-client==5.2.4 # via ipykernel, jupyter-console, notebook, qtconsole
jupyter-console==6.0.0 # via jupyter
Expand All @@ -45,51 +46,51 @@ mistune==0.8.4 # via nbconvert
more-itertools==7.0.0 # via pytest
nbconvert==5.4.1 # via jupyter, notebook
nbformat==4.4.0 # via ipywidgets, nbconvert, notebook
notebook==5.7.7 # via jupyter, jupyterlab, jupyterlab-server, widgetsnbextension
numpy==1.16.2 # via pandas
notebook==5.7.8 # via jupyter, jupyterlab, jupyterlab-server, widgetsnbextension
numpy==1.16.3 # via pandas
packaging==19.0 # via sphinx
pandas-mapper==0.1.2
pandas==0.24.2
pandocfilters==1.4.2 # via nbconvert
parso==0.3.4 # via jedi
pexpect==4.6.0 # via ipython
parso==0.4.0 # via jedi
pexpect==4.7.0 # via ipython
pickleshare==0.7.5 # via ipython
pluggy==0.9.0 # via pytest
prometheus-client==0.6.0 # via notebook
prompt-toolkit==2.0.9 # via ipython, jupyter-console
psycopg2==2.7.7
psycopg2==2.8.2
ptyprocess==0.6.0 # via pexpect, terminado
py==1.8.0 # via pytest
pygments==2.3.1 # via ipython, jupyter-console, nbconvert, qtconsole, sphinx
pylint==2.3.1
pyparsing==2.3.1 # via packaging
pyparsing==2.4.0 # via packaging
pyrsistent==0.14.11 # via jsonschema
pytest==4.3.1
pytest==4.4.1
python-dateutil==2.8.0 # via faker, jupyter-client, pandas
pytz==2018.9 # via babel, pandas
pytz==2019.1 # via babel, pandas
pyzmq==18.0.1 # via jupyter-client, notebook
qtconsole==4.4.3 # via jupyter
requests==2.21.0 # via sphinx
send2trash==1.5.0 # via notebook
six==1.12.0 # via astroid, bleach, faker, jsonschema, packaging, prompt-toolkit, pyrsistent, pytest, python-dateutil, traitlets
snowballstemmer==1.2.1 # via sphinx
sphinx-rtd-theme==0.4.3
sphinx==2.0.0
sphinx==2.0.1
sphinxcontrib-applehelp==1.0.1 # via sphinx
sphinxcontrib-devhelp==1.0.1 # via sphinx
sphinxcontrib-htmlhelp==1.0.1 # via sphinx
sphinxcontrib-htmlhelp==1.0.2 # via sphinx
sphinxcontrib-jsmath==1.0.1 # via sphinx
sphinxcontrib-qthelp==1.0.2 # via sphinx
sphinxcontrib-serializinghtml==1.1.1 # via sphinx
sqlalchemy==1.3.1
sphinxcontrib-serializinghtml==1.1.3 # via sphinx
sqlalchemy==1.3.3
tabulate==0.8.3
terminado==0.8.2 # via notebook
testpath==0.4.2 # via nbconvert
text-unidecode==1.2 # via faker
tornado==6.0.2 # via ipykernel, jupyter-client, notebook, terminado
traitlets==4.3.2 # via ipykernel, ipython, ipywidgets, jupyter-client, jupyter-core, nbconvert, nbformat, notebook, qtconsole
typed-ast==1.3.1 # via astroid
urllib3==1.24.1 # via requests
typed-ast==1.3.4 # via astroid
urllib3==1.24.2 # via requests
wcwidth==0.1.7 # via prompt-toolkit
webencodings==0.5.1 # via bleach
widgetsnbextension==3.4.2 # via ipywidgets
Expand Down
28 changes: 10 additions & 18 deletions tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,26 @@ def package_deploy(ctx):
ctx.run('twine upload dist/*')

@task
def compile_requirements(ctx):
def requirements_compile(ctx):
'''
Compile Python requirements without upgrading.
Docker images need to be rebuilt after running this (inv build).
'''
ctx.run('docker-compose run app inv pip-compile')

ctx.run('pip-compile requirements/base.in')
ctx.run('pip-compile requirements/doc.in')
ctx.run('pip-compile requirements/all.in')

@task
def upgrade_requirements(ctx):
def requirements_upgrade(ctx):
'''
Compile Python requirements with upgrading.
Docker images need to be rebuilt after running this (inv build).
'''
ctx.run('docker-compose run app inv pip-compile-upgrade')

ctx.run('pip-compile -U requirements/base.in')
ctx.run('pip-compile -U requirements/doc.in')
ctx.run('pip-compile -U requirements/all.in')

@task
def build(ctx):
Expand Down Expand Up @@ -102,17 +108,3 @@ def ps(ctx):
def shell(ctx):
'Start a shell running in the app container'
ctx.run('docker-compose run --rm app /bin/bash')

@task
def pip_compile(ctx):
'Compile pip resources. This should only be run in the container.'
ctx.run('pip-compile requirements/base.in')
ctx.run('pip-compile requirements/doc.in')
ctx.run('pip-compile requirements/all.in')

@task
def pip_compile_upgrade(ctx):
'Upgrate pip resources. This should only be run in the container.'
ctx.run('pip-compile -U requirements/base.in')
ctx.run('pip-compile -U requirements/doc.in')
ctx.run('pip-compile -U requirements/all.in')

0 comments on commit 018a3db

Please sign in to comment.