delete_port mistakenly uses string as input to _delete_ports_flowrules_by_id

Bug #1970517 reported by norman shen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
networking-sfc
In Progress
Undecided
Unassigned

Bug Description

https://github.com/openstack/networking-sfc/blob/b361517b04adbc7038b385a91e5f9d0e4ffe3a2a/networking_sfc/services/sfc/agent/extensions/sfc.py#L116

```python
    def delete_port(self, context, port):
        """Handle agent SFC extension port delete."""
        port_id = port['port_id']
        resync = False
        LOG.info("a device %s is removed", port_id)
        try:
            self._delete_ports_flowrules_by_id(context, port_id)
        except Exception as e:
            LOG.exception(e)
            LOG.error(
                "delete port flow rule failed for %(port_id)s",
                {'port_id': port_id}
            )
            resync = True

        return
```

function delete_port mistakenly call _delete_ports_flowrules_by_id with port_id as input, where it should be a list. As a result, delete_ports_flowrules_by_id will iterates through each character of the uuid which is weird.

Changed in networking-sfc:
status: New → In Progress
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.