Skip to content

Commit ae80536

Browse files
authored
Merge pull request #21577 from mvdbeek/fix-serialize-file-names
Don't return 404 when file name can't be serialized
2 parents 96856df + 2e42094 commit ae80536

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

lib/galaxy/managers/datasets.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,10 @@ def serialize_file_name(self, item, key, user=None, **context):
288288
# expensive: allow config option due to cost of operation
289289
if is_admin or self.app.config.expose_dataset_path:
290290
if not dataset.purged:
291-
return dataset.get_file_name(sync_cache=False)
291+
try:
292+
return dataset.get_file_name(sync_cache=False)
293+
except exceptions.ObjectNotFound:
294+
return None
292295
self.skip()
293296

294297
def serialize_extra_files_path(self, item, key, user=None, **context):

0 commit comments

Comments
 (0)