mirror of
https://github.com/apache/superset.git
synced 2026-05-23 08:45:45 +00:00
The change_detector script raised ValueError on scheduled workflow runs, breaking the daily CodeQL scan. Add a schedule branch alongside the existing workflow_dispatch branch since both trigger types aren't tied to a specific diff. While here, fix a latent bug: the workflow_dispatch branch printed "assuming all changed" but actually triggered nothing - it left files = [], and detect_changes([], ...) returns False, so no group flag was set in the output. Setting files = None makes the "files is None or detect_changes(...)" short-circuit fire for every group, matching the printed intent. Same fix benefits both event types. Other touch-ups: - Add the unsupported event name to the error message so future surprises are easier to debug. - Type files as Optional[List[str]] (mypy required this once the None branch was added). - Guard the len(files) check against None.