Files
galaxy/test/integration
mvdbeek 90cff585a4 Handle MaxDiscoveredFilesExceededError gracefully for dynamic collections
Tools whose only discoverable outputs are dynamic collections (no primary
assign_primary_output dataset) were raising MaxDiscoveredFilesExceededError
from inside collect_dynamic_outputs, where a blanket `except Exception`
swallowed it via `log.exception`, shipping a traceback to Sentry and
leaving the outer handlers in set_metadata_portable / MinimalJobWrapper
without the error to record in job_messages.

Catch MaxDiscoveredFilesExceededError in collect_dynamic_outputs, mark the
collection as population-failed, register it with the job context so the
FAILED state is serialized through the extended-metadata export store, and
re-raise so the outer handlers can record a max_discovered_files entry in
job_messages. Log at warning level instead of error in the outer handlers.

In set_metadata_portable the pre-_finalize export_job was redundant
(immediately overwritten by _finalize) so drop it; add a single
post-_finalize export_job in the error path because _finalize cannot find
the job through included_datasets / included_collections when discovery
failed before anything was added to them.

Fixes #22394
2026-04-07 11:23:23 +02:00
..
2026-01-26 19:43:38 +05:30
2021-03-25 14:01:17 +01:00
2026-01-20 10:25:45 +00:00
2025-02-25 19:20:46 +00:00
2025-07-31 11:17:22 +01:00
2022-11-28 04:50:00 +00:00
2025-03-26 18:07:57 +01:00
2025-09-23 22:16:20 +02:00
2024-09-19 09:39:08 +02:00
2025-02-16 18:07:51 +00:00
2025-07-31 11:17:22 +01:00