mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-10-29 17:42:12 +08:00
Fix history import by file on multi-handler setups
The uploaded archive was going to be deleted before the job started running.
This commit is contained in:
@@ -321,6 +321,9 @@ class HistoriesController(BaseAPIController, ExportsHistoryMixin, ImportsHistory
|
||||
if archive_source:
|
||||
archive_type = payload.get("archive_type", "url")
|
||||
elif hasattr(archive_file, "file"):
|
||||
# archive_file.file is a TemporaryFile and will be deleted once it is closed.
|
||||
# We prevent this by setting `delete` to `False`.
|
||||
archive_file.file.delete = False
|
||||
archive_source = payload["archive_file"].file.name
|
||||
archive_type = "file"
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user