Skip to content

Bug: fib/test_fib.py IPv6 only topo Not Supported #19923

@yanmo96

Description

@yanmo96

Is it platform specific

generic

Importance or Severity

Medium

Description of the bug

Still have IPv4 function in IPv6 test. Since this testbed is IPv6 only, not IPv4 with IPv6.

Steps to Reproduce

Run test on IPv6 only topo testbed.

Actual Behavior and Expected Behavior

May want to consider IPv6 only testbed. Or have a separate IPv6 test for it.

Relevant log output

E           _ansible_no_log = None
E           stdout =
E           Using packet manipulation module: ptf.packet_scapy
E           
E           ******************************************
E           ATTENTION: SOME TESTS DID NOT PASS!!!
E           
E           The following tests errored:
E           NvgreHashTest
E           
E           ******************************************stderr =
E           hash_test.NvgreHashTest
E           @summary: Send NvGRE packet for each range of both IPv4 and IPv6 spaces and ... ERROR
E           
E           ======================================================================
E           ERROR: hash_test.NvgreHashTest
E           @summary: Send NvGRE packet for each range of both IPv4 and IPv6 spaces and
E           ----------------------------------------------------------------------
E           Traceback (most recent call last):
E             File "/root/ptftests/py3/hash_test.py", line 1523, in runTest
E               self.check_hash(hash_key)
E             File "/root/ptftests/py3/hash_test.py", line 1487, in check_hash
E               src_port, exp_port_lists, next_hops = self.get_src_and_exp_ports(
E                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E             File "/root/ptftests/py3/hash_test.py", line 139, in get_src_and_exp_ports
E               next_hops = self._get_nexthops(src_port, dst_ip)
E                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E             File "/root/ptftests/py3/hash_test.py", line 132, in _get_nexthops
E               next_hops = [self.fibs[active_dut_index][dst_ip]
E                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E             File "/root/ptftests/py3/hash_test.py", line 132, in <listcomp>
E               next_hops = [self.fibs[active_dut_index][dst_ip]
E                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^
E             File "/root/ptftests/py3/fib.py", line 75, in __getitem__
E               return self._ipv4_lpm_dict[str(ip)]
E                      ~~~~~~~~~~~~~~~~~~~^^^^^^^^^
E             File "/root/ptftests/py3/lpm.py", line 79, in __getitem__
E               return self._subnet_tree[key]
E                      ~~~~~~~~~~~~~~~~~^^^^^
E             File "/root/env-python3/lib/python3.11/site-packages/SubnetTree.py", line 162, in __getitem__
E               return _SubnetTree.SubnetTree___getitem__(self, cidr)
E                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: '80.1.0.32'
E           
E           ----------------------------------------------------------------------
E           Ran 1 test in 0.903s
E           
E           FAILED (errors=1)

complex_args = {'chdir': '/root'}
filename   = '/var/src/sonic-mgmt_vms75-t0-sn5640-7/tests/ptf_runner.py'
function_name = 'ptf_runner'
index      = 0
line_number = 206
lines      = ['        result = host.shell(cmd, chdir="/root", module_ignore_errors=module_ignore_errors, module_async=async_mode)\n']
module_args = ['/root/env-python3/bin/ptf --test-dir ptftests/py3 hash_test.NvgreHashTest --platform-dir ptftests --qlen=2000000 --p...lax --debug info --log-file /tmp/hash_test.NvgreHashTest.ipv6-ipv6.2025-07-20-03:06:13.log --socket-recv-size 1638400']

Output of show version

Attach files (if any)

No response

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions