From 780dee633cc1e9b6bebeb8131440b60cc7c1fe8b Mon Sep 17 00:00:00 2001 From: Keiran Price Date: Thu, 26 Sep 2019 10:47:26 +0100 Subject: [PATCH 1/4] #72: Update README.md --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 0a3ba221..1d907c7e 100644 --- a/README.md +++ b/README.md @@ -13,12 +13,15 @@ ICAT API to interface with the Data Gateway ## Requirements +All requirements can be installed with `pip install -r requirements.txt` + The required python libraries: - [SQLAlchemy](https://www.sqlalchemy.org/) - [flask-restful](https://github.com/flask-restful/flask-restful/) - [pymysql](https://pymysql.readthedocs.io/en/latest/) - [requests](https://2.python-requests.org/en/master/) - [pyyaml](https://pyyaml.org/wiki/PyYAMLDocumentation) (For the swagger generation) + - [pip-tools](https://github.com/jazzband/pip-tools) (For generating requirements.txt) ## Setup and running the API The database connection needs to be set up first. This is set in config.json, an example config file called `config.json.example` is provided. From b7bfc48b49b1bd75c8a59a4b2462abc885d769cf Mon Sep 17 00:00:00 2001 From: Keiran Price Date: Thu, 26 Sep 2019 10:47:54 +0100 Subject: [PATCH 2/4] #72: Add requirements.in --- requirements.in | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 requirements.in diff --git a/requirements.in b/requirements.in new file mode 100644 index 00000000..111d19a0 --- /dev/null +++ b/requirements.in @@ -0,0 +1,5 @@ +flask_restful +sqlalchemy +pymysql +pyyaml +pip-tools \ No newline at end of file From 96441b32ab7570ad9259a909fad3ad118ed83e09 Mon Sep 17 00:00:00 2001 From: Keiran Price Date: Thu, 26 Sep 2019 10:48:09 +0100 Subject: [PATCH 3/4] #72: Generate requirements.txt --- requirements.txt | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 requirements.txt diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 00000000..063a1ef3 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,20 @@ +# +# This file is autogenerated by pip-compile +# To update, run: +# +# pip-compile +# +aniso8601==8.0.0 # via flask-restful +click==7.0 # via flask, pip-tools +flask-restful==0.3.7 +flask==1.1.1 # via flask-restful +itsdangerous==1.1.0 # via flask +jinja2==2.10.1 # via flask +markupsafe==1.1.1 # via jinja2 +pip-tools==4.1.0 +pymysql==0.9.3 +pytz==2019.2 # via flask-restful +pyyaml==5.1.2 +six==1.12.0 # via flask-restful, pip-tools +sqlalchemy==1.3.8 +werkzeug==0.16.0 # via flask From da0622f2e5a693c2057af567874a37fd57ac521b Mon Sep 17 00:00:00 2001 From: Keiran Price Date: Thu, 26 Sep 2019 11:05:55 +0100 Subject: [PATCH 4/4] #72: Add versions and remove pip-tools --- requirements.in | 9 ++++----- requirements.txt | 7 +++---- 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/requirements.in b/requirements.in index 111d19a0..77a79dbe 100644 --- a/requirements.in +++ b/requirements.in @@ -1,5 +1,4 @@ -flask_restful -sqlalchemy -pymysql -pyyaml -pip-tools \ No newline at end of file +flask_restful == 0.3.7 +sqlalchemy == 1.3.8 +pymysql == 0.9.3 +pyyaml == 5.1.2 diff --git a/requirements.txt b/requirements.txt index 063a1ef3..4b29aa69 100644 --- a/requirements.txt +++ b/requirements.txt @@ -5,16 +5,15 @@ # pip-compile # aniso8601==8.0.0 # via flask-restful -click==7.0 # via flask, pip-tools -flask-restful==0.3.7 +click==7.0 # via flask flask==1.1.1 # via flask-restful +flask_restful==0.3.7 itsdangerous==1.1.0 # via flask jinja2==2.10.1 # via flask markupsafe==1.1.1 # via jinja2 -pip-tools==4.1.0 pymysql==0.9.3 pytz==2019.2 # via flask-restful pyyaml==5.1.2 -six==1.12.0 # via flask-restful, pip-tools +six==1.12.0 # via flask-restful sqlalchemy==1.3.8 werkzeug==0.16.0 # via flask