[bitbake-devel] [PATCH 5/8] runqueue.py: check results[0] in keys of build_pids before being used to avoid exceptions

Chris Larson clarson at kergoth.com
Fri Mar 30 06:15:45 UTC 2012


On Thu, Mar 29, 2012 at 11:10 PM, Wang, Shane <shane.wang at intel.com> wrote:
>> So can you please explain the problem further so we can fix the real
>> problem? I did look at #2186 but that doesn't help me either :(
> OK, I am going to submit another patch, but I think the condition check is also needed.
> Otherwise, in the current code of runqueue_process_waitpid(), why do we have:
>        if result[0] in self.build_stamps.keys():
>            del self.build_stamps[result[0]]

This is also off, from a code standpoint, even assuming it's needed.
There's no need to use the keys method at all for a map. 'in' against
a map automatically checks by key. result[0] in self.build_stamps.
-- 
Christopher Larson




More information about the bitbake-devel mailing list