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
Traceback (most recent call last):
File "<test_file>", line 5, in <module>
EthPortTable(dev).get()
^^^^^^^^^^^^^^^^^
File "<package_install_dir>\jnpr\junos\factory\table.py", line 37, in __init__
self._use_filter = self._use_filter and self._dev._use_filter
^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'Console' object has no attribute '_use_filter'
The text was updated successfully, but these errors were encountered:
Additionally, manually setting the _use_filter attribute on the allows us to proceed, but the test code then fails with:
File "<package_install_dir>\jnpr\junos\console.py", line 276, in _rpc_reply
rpc_rsp_e = NCElement(
File "<package_install_dir>\ncclient\xml_.py", line 177, in __init__
self.__doc = self.__transform_reply(result._root)
^^^^^^^^^^^^
AttributeError: 'str' object has no attribute '_root'
This issue is mitigated by modifying tty_netconf's rpc method to return reply rather than return rsp. rsp is a string, and of course, does not possess a _root attribute.
The following code manually sets the missing Console attribute and monkey patches the rpc method to return as needed. When executed, the expected output (identical to using the Device class over SSH) is returned.
The
Console
object does not have the_use_filter
attribute that the regularDevice
class provides.The
Table
class expects this to be available. An error is thrown initializing aTable
using aConsole
.Reproduce with:
Yields:
The text was updated successfully, but these errors were encountered: