diff --git a/.cookiecutter.json b/.cookiecutter.json index 9352cbe4bc33c225df97295b776db34fb52e85ea..c4dd6ab585ccedd1eab18990bfedfb297595a242 100644 --- a/.cookiecutter.json +++ b/.cookiecutter.json @@ -6,3 +6,4 @@ "author": "Nishanth artham", "email": "arthamnishanth123@gmail.com" } + \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index 5aaea2863a2a191c84e6ca3cbe197d5d0fb3213d..7355c65fdff2b41d96f2d6a07e54563b5475f646 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,7 +3,7 @@ FROM python:3 WORKDIR /src # Install worker as a package -COPY worker_{{cookiecutter.slug}} worker_{{cookiecutter.slug}} +COPY worker_palmira worker_palmira COPY requirements.txt setup.py VERSION ./ RUN pip install . @@ -11,4 +11,4 @@ RUN pip install . RUN curl https://assets.teklia.com/teklia_dev_ca.pem > /usr/local/share/ca-certificates/arkindex-dev.crt && update-ca-certificates ENV REQUESTS_CA_BUNDLE /etc/ssl/certs/ca-certificates.crt -CMD ["worker-{{ cookiecutter.slug }}"] +CMD ["worker-palmira"] diff --git a/setup.py b/setup.py index 3f9cc17fb6d5a13ac872e6577d0ebd78d3f10ceb..bc059984eb5a20808582008d61b7161d0a23c14b 100755 --- a/setup.py +++ b/setup.py @@ -5,8 +5,8 @@ from pathlib import Path from setuptools import find_packages, setup -MODULE = "worker_{{cookiecutter.slug}}" -COMMAND = "worker-{{cookiecutter.slug}}" +MODULE = "worker_palmira" +COMMAND = "worker-palmira" def parse_requirements_line(line): @@ -33,9 +33,9 @@ def parse_requirements(): setup( name=MODULE, version=open("VERSION").read(), - description="{{ cookiecutter.description }}", - author="{{ cookiecutter.author }}", - author_email="{{ cookiecutter.email }}", + description="Palm Leaf Manuscript Region Annotator", + author="Nishanth artham", + author_email="arthamnishanth123@gmail.com", install_requires=parse_requirements(), entry_points={"console_scripts": [f"{COMMAND}={MODULE}.worker:main"]}, packages=find_packages(), diff --git a/tests/conftest.py b/tests/conftest.py index bca0563ef4bc7f367068e754ae7c3134715eb636..d70fa74128770a4e3a661477850e910552932c55 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -22,7 +22,7 @@ def setup_environment(responses, monkeypatch): # Set schema url in environment os.environ["ARKINDEX_API_SCHEMA_URL"] = schema_url # Setup a fake worker run ID - os.environ["ARKINDEX_WORKER_RUN_ID"] = "1234-{{ cookiecutter.slug }}" + os.environ["ARKINDEX_WORKER_RUN_ID"] = "1234-palmira" # Setup a mock api client instead of using a real one monkeypatch.setattr(BaseWorker, "setup_api_client", lambda _: MockApiClient()) diff --git a/tests/test_worker.py b/tests/test_worker.py index b995a94f30ef8f7864baba1946717fe923e302b8..7beb99ae4eec1359678f676a16675b9563c40ad5 100644 --- a/tests/test_worker.py +++ b/tests/test_worker.py @@ -8,6 +8,6 @@ def test_dummy(): def test_import(): """Import our newly created module, through importlib to avoid parsing issues""" - worker = importlib.import_module("worker_{{ cookiecutter.slug }}.worker") + worker = importlib.import_module("worker_palmira.worker") assert hasattr(worker, "Demo") assert hasattr(worker.Demo, "process_element")