diff --git a/.github/workflows/main.workflow.yml b/.github/workflows/main.workflow.yml index 9b33db443..b5b1fe974 100644 --- a/.github/workflows/main.workflow.yml +++ b/.github/workflows/main.workflow.yml @@ -24,5 +24,18 @@ jobs: run: docker network create top_and_zaak_backend_bridge - name: Start images run: docker compose -f docker-compose.local.yml up -d + - run: sleep 30 - name: Run Tests run: docker compose -f docker-compose.local.yml exec -T zaak-gateway python manage.py test + + - if: ${{ failure() }} + name: "ON FAILURE: Which containers were running while failing?" + run: docker ps -a + + - if: ${{ failure() }} + name: "ON FAILURE: Backend logs" + run: docker logs zaken-backend-zaak-gateway-1 + + - if: ${{ failure() }} + name: "ON FAILURE: Database logs" + run: docker logs zaken-backend-database-1 diff --git a/app/apps/workflow/signals.py b/app/apps/workflow/signals.py index bcf94a1e5..bae32f010 100644 --- a/app/apps/workflow/signals.py +++ b/app/apps/workflow/signals.py @@ -1,5 +1,6 @@ import copy import datetime +import logging import pytz from apps.events.models import TaskModelEventEmitter @@ -16,6 +17,8 @@ from .user_tasks import DEFAULT_USER_TASK_DUE_DATE, get_task_by_name from .utils import get_latest_version_from_config +logger = logging.getLogger(__name__) + @receiver(pre_save, dispatch_uid="event_emitter_pre_save") def event_emitter_pre_save(instance, **kwargs): @@ -36,6 +39,9 @@ def event_emitter_pre_save(instance, **kwargs): case_user_task_id=instance.case_user_task_id ) if type_instance: + logger.error( + f"TaskModelEventEmitter of type '{instance.__class__.__name__}', with id '{instance.case_user_task_id}', already exists" + ) raise EventEmitterExistsError( f"TaskModelEventEmitter of type '{instance.__class__.__name__}', with id '{instance.case_user_task_id}', already exists" )