]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
pybind/mgr/progress: enforced try and except on accessing event dictionary
authorKamoltat <ksirivad@redhat.com>
Wed, 12 Jan 2022 02:41:01 +0000 (02:41 +0000)
committerKamoltat <ksirivad@redhat.com>
Wed, 12 Jan 2022 02:41:01 +0000 (02:41 +0000)
commitb70d4a9caae0eb859e10b68f93573d507625d267
tree5e428e28ea352d5bc6d439a3dc528ec2495e868c
parent69ac8a44762fb1ff1652dfe3e954fc811b58a1af
pybind/mgr/progress: enforced try and except on accessing event dictionary

There is a certain race condition scenario where
an event gets deleted while the progress module
iterates through the ``events`` dictionary,
without a ``try and except``, this will cause
an unhandled exception error and will crash
the module.

This commit will enforce ``try and except``
on every part of the code where we are accessing
the ``events`` dictionary.

Fixes: https://tracker.ceph.com/issues/53803
Signed-off-by: Kamoltat <ksirivad@redhat.com>
src/pybind/mgr/progress/module.py