]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
checklayer: fix get_depgraph() hang when command fails
authorTim Orling <tim.orling@konsulko.com>
Sun, 15 Feb 2026 22:10:57 +0000 (14:10 -0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 19 Feb 2026 10:31:29 +0000 (10:31 +0000)
commita2c6bf582287a56ae241499598d3038b3c3cdb4f
treed517a11c9f682ec871fb62c4b5d44d3d0753637b
parentb63c3507f0d48691269f39d7c0ae43ffe7a6cc67
checklayer: fix get_depgraph() hang when command fails

The get_depgraph() function hangs indefinitely when a layer causes
command failures (e.g. meta-virtualization) because:

1. bb.command.CommandFailed was not included in the event mask passed
   to set_event_mask(), so the failure event was silently dropped and
   the while True loop never received a terminating event.

2. There was no timeout handling for the case where wait_event()
   repeatedly returns None, leaving no escape from the loop.

Add CommandFailed to the event mask so failure events are properly
received and handled. Also add a timeout counter that raises
RuntimeError after 300 consecutive seconds of no events, preventing
an infinite hang.

Fixes [YOCTO #16170]

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
scripts/lib/checklayer/__init__.py