The issue happens after adding an IPv6 subnet, so I suspect that the query returns multiple gateways, one for IPv4 and one for IPv6.
If this assumption is correct, then the solution would be to restrict the query to Subnets having ip_version == 4 (which makes a lot of sense anyways, until we support v6).
The issue happens after adding an IPv6 subnet, so I suspect that the query returns multiple gateways, one for IPv4 and one for IPv6.
If this assumption is correct, then the solution would be to restrict the query to Subnets having ip_version == 4 (which makes a lot of sense anyways, until we support v6).