Hi,

I have a board with 4 uarts connected to a lava worker via ser2net.

LAVA is giving me some strange results when I try to use two uarts (uart0 and uart2) in the same testcase.
The results are not consistent. Sometimes it works, but most of the time it gives an error:

KeyError: 'uart2'

At the end of the job, LAVA prints:

LAVABug: This is probably a bug in LAVA, please report it.error_type: Bug
error_msg: 'uart2'
case: job
result: fail
definition: lava

----

The connection parts of the device definition are:

% set connection_list = ['uart0', 'uart1', 'uart2', 'uart3'] %}
{% set connection_tags = {'uart0': ['primary', 'telnet']} %}
{% set connection_commands = {'uart0': 'telnet localhost 7001', 'uart1': 'telnet localhost 7002', 'uart2': 'telnet localhost 7003', 'uart3': 'telnet localhost 7004'} %}

The job uses two boots; one primary to boot non-POSIX to uboot, then it switches to 'uart2' to access another processor.

The job seems to work fine if I define only two uarts:

% set connection_list = ['uart0', 'uart1'] %}
{% set connection_tags = {'uart0': ['primary', 'telnet']} %}
{% set connection_commands = {'uart0': 'telnet localhost 7001',  'uart1': 'telnet localhost 7003 } %}

Thank you,

Nick