From eddd80be53a1712ee470391dfa3dec4c1d2c5cf6 Mon Sep 17 00:00:00 2001 From: Dave Walker Date: Tue, 9 Jan 2024 19:10:16 +0000 Subject: [PATCH] Fixup vulnerable fonttools dependency --- docker/Dockerfile | 10 +++++----- requirements.txt | 2 +- run_behave.sh | 7 ------- run_coverage.bat | 1 + run_coverage.sh | 7 ------- run_locust.sh | 7 ------- run_tests.sh | 6 ------ run_web.sh | 8 -------- setup.py | 2 +- 9 files changed, 8 insertions(+), 42 deletions(-) delete mode 100644 run_behave.sh delete mode 100644 run_coverage.sh delete mode 100644 run_locust.sh delete mode 100644 run_tests.sh delete mode 100644 run_web.sh diff --git a/docker/Dockerfile b/docker/Dockerfile index 47b0646..f82fca4 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,15 +1,15 @@ FROM python:3.10-slim-bullseye AS runtime -COPY naturerecorderpy-1.1.0.0 /opt/naturerecorderpy-1.1.0.0 +COPY naturerecorderpy-1.1.1.0 /opt/naturerecorderpy-1.1.1.0 -WORKDIR /opt/naturerecorderpy-1.1.0.0 +WORKDIR /opt/naturerecorderpy-1.1.1.0 RUN apt-get update -y RUN pip install -r requirements.txt -RUN pip install nature_recorder-1.1.0-py3-none-any.whl +RUN pip install nature_recorder-1.1.1-py3-none-any.whl -ENV NATURE_RECORDER_DATA_FOLDER=/var/opt/naturerecorderpy-1.1.0.0 -ENV NATURE_RECORDER_DB=/var/opt/naturerecorderpy-1.1.0.0/naturerecorder.db +ENV NATURE_RECORDER_DATA_FOLDER=/var/opt/naturerecorderpy-1.1.1.0 +ENV NATURE_RECORDER_DB=/var/opt/naturerecorderpy-1.1.1.0/naturerecorder.db ENTRYPOINT [ "python" ] CMD [ "-m", "naturerec_web", "production" ] diff --git a/requirements.txt b/requirements.txt index 4bf4c16..456337d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -21,7 +21,7 @@ Flask-BasicAuth==0.2.0 Flask-Cors==4.0.0 Flask-Login==0.6.3 Flask-WTF==1.2.1 -fonttools==4.29.1 +fonttools==4.43.0 gevent==21.12.0 geventhttpclient==2.0.11 greenlet==1.1.2 diff --git a/run_behave.sh b/run_behave.sh deleted file mode 100644 index a916e29..0000000 --- a/run_behave.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/zsh -f - -export PROJECT_ROOT=$( cd "$(dirname "$0")" ; pwd -P ) -source "$PROJECT_ROOT/venv/bin/activate" -export PYTHONPATH="$PROJECT_ROOT/src" -export NATUREREC_SAME_PAGE_REPORT="" -behave diff --git a/run_coverage.bat b/run_coverage.bat index b31a068..209e7a2 100644 --- a/run_coverage.bat +++ b/run_coverage.bat @@ -2,6 +2,7 @@ SET PROJECT_ROOT=%~p0 CALL %PROJECT_ROOT%\venv\Scripts\activate.bat SET PYTHONPATH=%PROJECT_ROOT%src +SET NATURE_RECORDER_DB=%PROJECT_ROOT%\data\naturerecorder_test.db ECHO Project root = %PROJECT_ROOT% ECHO Python Path = %PYTHONPATH% diff --git a/run_coverage.sh b/run_coverage.sh deleted file mode 100644 index 6ee5022..0000000 --- a/run_coverage.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/zsh -f - -export PROJECT_ROOT=$( cd "$(dirname "$0")" ; pwd -P ) -source "$PROJECT_ROOT/venv/bin/activate" -export PYTHONPATH="$PROJECT_ROOT/src" -coverage run --branch --source src -m unittest discover -coverage html -d cov_html diff --git a/run_locust.sh b/run_locust.sh deleted file mode 100644 index bb9e990..0000000 --- a/run_locust.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/zsh -f - -export PROJECT_ROOT=$( cd "$(dirname "$0")" ; pwd -P ) -source "$PROJECT_ROOT/venv/bin/activate" -export PYTHONPATH="$PROJECT_ROOT/src:$PROJECT_ROOT/tests" -cd tests/locust_tests -locust -f locustfile.py diff --git a/run_tests.sh b/run_tests.sh deleted file mode 100644 index c3fd90c..0000000 --- a/run_tests.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/zsh -f - -export PROJECT_ROOT=$( cd "$(dirname "$0")" ; pwd -P ) -source "$PROJECT_ROOT/venv/bin/activate" -export PYTHONPATH="$PROJECT_ROOT/src" -python -m unittest diff --git a/run_web.sh b/run_web.sh deleted file mode 100644 index adfe45d..0000000 --- a/run_web.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/zsh -f - -export PROJECT_ROOT=$( cd "$(dirname "$0")" ; pwd -P ) -source "$PROJECT_ROOT/venv/bin/activate" -export PYTHONPATH="$PROJECT_ROOT/src" -export NATURE_RECORDER_DB="$PROJECT_ROOT/data/naturerecorder.db" -export FLASK_ENV=development -python -m naturerec_web diff --git a/setup.py b/setup.py index 98f569f..98f7a80 100644 --- a/setup.py +++ b/setup.py @@ -31,7 +31,7 @@ def find_package_files(directory, remove_root): setuptools.setup( name="nature_recorder", - version="1.1.0", + version="1.1.1", description="Wildlife sightings database", packages=setuptools.find_packages("src"), include_package_data=True,