diff --git a/mula/Makefile b/mula/Makefile index 75159fd7509..7d9724afed5 100644 --- a/mula/Makefile +++ b/mula/Makefile @@ -84,14 +84,14 @@ else ifeq ($(revid),) $(HIDE) (echo "ERROR: Specify a message with m={message} and a rev-id with revid={revid} (e.g. 0001 etc.)"; exit 1) else docker compose run --rm scheduler \ - alembic --config /app/scheduler/scheduler/alembic.ini \ + alembic --config /app/scheduler/scheduler/storage/migrations/alembic.ini \ revision --autogenerate \ -m "$(m)" --rev-id "$(revid)" endif migrate: ## Run migrations using alembic. docker compose run scheduler \ - alembic --config /app/scheduler/scheduler/alembic.ini \ + alembic --config /app/scheduler/scheduler/storage/migrations/alembic.ini \ upgrade head ## diff --git a/mula/entrypoint.sh b/mula/entrypoint.sh index 7e52612a54a..cdaf19c6b8c 100755 --- a/mula/entrypoint.sh +++ b/mula/entrypoint.sh @@ -5,7 +5,7 @@ set -e shopt -s nocasematch if [ "$DATABASE_MIGRATION" = "1" ] || [[ $DATABASE_MIGRATION == "true" ]]; then - python -m alembic --config /app/scheduler/scheduler/alembic.ini upgrade head + python -m alembic --config /app/scheduler/scheduler/storage/migrations/alembic.ini upgrade head fi exec "$@" diff --git a/mula/scheduler/schedulers/scheduler.py b/mula/scheduler/schedulers/scheduler.py index c8200dadd8f..659913e1594 100644 --- a/mula/scheduler/schedulers/scheduler.py +++ b/mula/scheduler/schedulers/scheduler.py @@ -11,8 +11,7 @@ from scheduler import clients, context, models, storage, utils from scheduler.schedulers.queue import PriorityQueue -from scheduler.schedulers.queue.errors import (InvalidItemError, - NotAllowedError, QueueFullError) +from scheduler.schedulers.queue.errors import InvalidItemError, NotAllowedError, QueueFullError from scheduler.utils import cron, thread tracer = trace.get_tracer(__name__) @@ -117,7 +116,7 @@ def push_items_to_queue(self, items: list[models.Task]) -> None: queue_id=self.queue.pq_id, scheduler_id=self.scheduler_id, ) - continue u + continue except Exception as exc: self.logger.error( "Unable to push item %s to queue %s",