diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 109abd370..d42990f39 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -74,6 +74,5 @@ jobs: docker exec test_ckan $WORKDIR/bin/install_test_requirements.sh - name: Run tests run: | - docker ps docker exec test_ckan pytest --ckan-ini=$WORKDIR/test.ini --disable-warnings --cov=ckanext.switzerland \ $WORKDIR/ckanext/switzerland/tests diff --git a/bin/install_test_requirements.sh b/bin/install_test_requirements.sh index c941309db..9b9d51441 100755 --- a/bin/install_test_requirements.sh +++ b/bin/install_test_requirements.sh @@ -2,7 +2,7 @@ # Install requirements and ckanext pip install -r /__w/ckanext-switzerland/ckanext-switzerland/requirements.txt -pip install -r /__w/ckanext-switzerland/ckanext-switzerland/dev-requirements.txt +pip install --ignore-installed -r /__w/ckanext-switzerland/ckanext-switzerland/dev-requirements.txt pip install -e /__w/ckanext-switzerland/ckanext-switzerland/ # Install ckanext dependencies diff --git a/ckanext/switzerland/harvester/s3_storage_adapter.py b/ckanext/switzerland/harvester/s3_storage_adapter.py index 320fa3b22..f797c7cda 100644 --- a/ckanext/switzerland/harvester/s3_storage_adapter.py +++ b/ckanext/switzerland/harvester/s3_storage_adapter.py @@ -9,6 +9,7 @@ ... ` """ + import datetime import logging import os diff --git a/ckanext/switzerland/templates/package/read.html b/ckanext/switzerland/templates/package/read.html index 5ac069b9a..00bc9329d 100644 --- a/ckanext/switzerland/templates/package/read.html +++ b/ckanext/switzerland/templates/package/read.html @@ -4,21 +4,6 @@ {% block maintag_class %}dataset-detail{% endblock %} -{% block page_title %} - {% if pkg.private %} - {{ _('Private') }} - {% endif %} -

- {{ h.dataset_display_name(pkg) }} - {% if pkg.state.startswith('draft') %} - [{{ _('Draft') }}] - {% endif %} - {% if pkg.state == 'deleted' %} - [{{ _('Deleted') }}] - {% endif %} -

-{% endblock %} - {% block primary_content_inner %} {% block package_revision_info %} @@ -34,17 +19,20 @@

{% endif %} {% endblock %} -

{% block page_heading %} - {{ h.dataset_display_name(pkg) }} - {% if pkg.state.startswith('draft') %} - [{{ _('Draft') }}] - {% endif %} - {% if pkg.state == 'deleted' %} - [{{ _('Deleted') }}] + {% if pkg.private %} + {{ _('Private') }} {% endif %} +

+ {{ h.dataset_display_name(pkg) }} + {% if pkg.state.startswith('draft') %} + [{{ _('Draft') }}] + {% endif %} + {% if pkg.state == 'deleted' %} + [{{ _('Deleted') }}] + {% endif %} +

{% endblock %} - {% block package_description %} {% snippet "package/snippets/description.html", pkg=pkg %} diff --git a/dev-requirements.txt b/dev-requirements.txt index d8cc02423..a891224e9 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -1,9 +1,10 @@ -black==22.12.0 -flake8==6.1.0 +black==24.1.1 +flake8==7.0.0 fs==2.4.16 -isort==5.12.0 +isort==5.13.2 mock==5.1.0 numpy==1.25.2 +pycodestyle==2.11.1 pytest==7.1.3 pytest-ckan==0.0.12 pytest-cov==3.0.0