You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We encountered a bug while calling the STL api in custom Python scripts.
Bug appears in Python2 and Python3.
OS : Ubuntu 14.04 LTS (recommended)
Trex version : 2.43
Bug summary : When calling "wait_on_traffic" method on an STLClient instance, trying to raise TRexTimeoutError will result as an error as it is not defined.
It is defined in /automation/trex_control_plane/interactive/trex/common/trex_exceptions.py, but not in __all__.
To fix it, change "trex_exceptions.py:8" :
__all__ = ["TRexError", "TRexArgumentError", "TRexTypeError"]
To :
__all__ = ["TRexError", "TRexArgumentError", "TRexTypeError", "TRexTimeoutError"]
And maybe add the "TRexConsoleError" and "TRexConsoleNoAction" to this list.
Backtrace :
c.wait_on_traffic(ports = conf_port, timeout = 2*duration)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/common/trex_api_annotators.py", line 51, in wrap2
ret = f(*args, **kwargs)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/stl/trex_stl_client.py", line 602, in wait_on_traffic
TRexClient.wait_on_traffic(self, ports, timeout)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/common/trex_api_annotators.py", line 51, in wrap2
ret = f(*args, **kwargs)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/common/trex_client.py", line 1620, in wait_on_traffic
raise TRexTimeoutError(timeout)
NameError: name 'TRexTimeoutError' is not defined
The text was updated successfully, but these errors were encountered:
Hi,
We encountered a bug while calling the STL api in custom Python scripts.
Bug appears in Python2 and Python3.
OS : Ubuntu 14.04 LTS (recommended)
Trex version : 2.43
Bug summary : When calling "wait_on_traffic" method on an STLClient instance, trying to raise TRexTimeoutError will result as an error as it is not defined.
It is defined in /automation/trex_control_plane/interactive/trex/common/trex_exceptions.py, but not in __all__.
To fix it, change "trex_exceptions.py:8" :
__all__ = ["TRexError", "TRexArgumentError", "TRexTypeError"]
To :
__all__ = ["TRexError", "TRexArgumentError", "TRexTypeError", "TRexTimeoutError"]
And maybe add the "TRexConsoleError" and "TRexConsoleNoAction" to this list.
Backtrace :
c.wait_on_traffic(ports = conf_port, timeout = 2*duration)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/common/trex_api_annotators.py", line 51, in wrap2
ret = f(*args, **kwargs)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/stl/trex_stl_client.py", line 602, in wait_on_traffic
TRexClient.wait_on_traffic(self, ports, timeout)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/common/trex_api_annotators.py", line 51, in wrap2
ret = f(*args, **kwargs)
File "/home/trex/trex/v2.43/automation/trex_control_plane/interactive/trex/common/trex_client.py", line 1620, in wait_on_traffic
raise TRexTimeoutError(timeout)
NameError: name 'TRexTimeoutError' is not defined
The text was updated successfully, but these errors were encountered: