From eba3bd71fe39aa91177d50eb5d18ca7706c26bc7 Mon Sep 17 00:00:00 2001 From: metricsmancer Date: Fri, 20 Mar 2026 07:54:43 +0100 Subject: T8404: fix TypeError when ipv6 address node exists without autoconf dict_search('ipv6.address', config) returns None when the ipv6 address node is empty (e.g. after deleting autoconf), causing a TypeError on the 'in' membership test. Use dict_search('ipv6.address.autoconf', config) instead, which safely returns None for any missing path segment. --- python/vyos/ifconfig/pppoe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'python') diff --git a/python/vyos/ifconfig/pppoe.py b/python/vyos/ifconfig/pppoe.py index c20c6efaa..2a89cbddd 100644 --- a/python/vyos/ifconfig/pppoe.py +++ b/python/vyos/ifconfig/pppoe.py @@ -142,5 +142,5 @@ class PPPoEIf(Interface): self._cmd(f'vtysh -c "conf t" {vrf} -c "ipv6 route ::/0 {self.ifname} tag 210 {distance}"') # kick RS when IPv6 is up. - if 'autoconf' in dict_search('ipv6.address', config): + if dict_search('ipv6.address.autoconf', config) is not None: self._cmd(f'rdisc6 --single --retry 3 {self.ifname}') -- cgit v1.2.3