After looking into code it seems for me that it is race in calling "_ensure_default_security_group" method from "get_security_group_rules" and also from "_ensure_default_security_group_handler" which is subscribed e.g. to port's BEFORE_UPDATE even.
This is probably caused by https://github.com/openstack/neutron/commit/4739a4febb8c77e5a0ca48bc77ae4dccd9f8a81e which added calling this method from get_security_group_rules().
I will try to propose fix for that this week.
After looking into code it seems for me that it is race in calling "_ensure_ default_ security_ group" method from "get_security_ group_rules" and also from "_ensure_ default_ security_ group_handler" which is subscribed e.g. to port's BEFORE_UPDATE even.
This is probably caused by https:/ /github. com/openstack/ neutron/ commit/ 4739a4febb8c77e 5a0ca48bc77ae4d ccd9f8a81e which added calling this method from get_security_ group_rules( ).
I will try to propose fix for that this week.