diff --git a/embark/uploader/boundedexecutor.py b/embark/uploader/boundedexecutor.py index 0daa7a88..36585bcc 100644 --- a/embark/uploader/boundedexecutor.py +++ b/embark/uploader/boundedexecutor.py @@ -19,6 +19,7 @@ from django.dispatch import receiver from django.utils import timezone from django.conf import settings +from django.db import close_old_connections from uploader import finish_execution from uploader.archiver import Archiver @@ -96,6 +97,7 @@ def run_emba_cmd(cls, cmd, analysis_id=None, active_analyzer_dir=None): if return_code != 0: raise BoundedException("EMBA has non zero exit-code") + close_old_connections() # get csv log location csv_log_location = f"{settings.EMBA_LOG_ROOT}/{analysis_id}/emba_logs/csv_logs/f50_base_aggregator.csv"