VOL-495 Align no-route behavior in flow_decomposer for multicast with unicast (check for None)
Change-Id: I17d41dbd52f042cb450ebf07fd800052a2bbc939
diff --git a/voltha/core/flow_decomposer.py b/voltha/core/flow_decomposer.py
index 8f4e6bd..cfc4940 100644
--- a/voltha/core/flow_decomposer.py
+++ b/voltha/core/flow_decomposer.py
@@ -450,6 +450,8 @@
self._device == other._device and
self._ingress_port == other._ingress_port and
self._egress_port == other._egress_port)
+ def __ne__(self, other):
+ return not self.__eq__(other)
class FlowDecomposer(object):
@@ -678,6 +680,11 @@
# re-run route request to determine egress device and
# ports
route2 = self.get_route(in_port_no, out_port_no)
+ if route2 is None:
+ log.error('mc-no-route', in_port_no=in_port_no,
+ out_port_no=out_port_no, route2=route2,
+ comment='ignoring flow')
+ continue
assert len(route2) == 2
ingress_hop2, egress_hop = route2