Skip to content

bad-element error with netconf filter #108

@HeikkiLavaste

Description

@HeikkiLavaste

Hi.

If I connect to one of the sandbox XE devices, the filter works fine. (dne-dna-code/intro-mdp/netconf/get_interface_list.py)
If I connect to CSR running locally (XE 17.03.02), I get following error.

Sending a operation to the device.

Traceback (most recent call last):
File "get_interface_list.py", line 65, in
netconf_reply = m.get_config(source = 'running', filter=netconf_filter)
File "/home/heikki/.local/lib/python3.8/site-packages/ncclient/manager.py", line 212, in execute
return cls(self._session,
File "/home/heikki/.local/lib/python3.8/site-packages/ncclient/operations/retrieve.py", line 166, in request
return self._request(node)
File "/home/heikki/.local/lib/python3.8/site-packages/ncclient/operations/rpc.py", line 341, in _request
raise self._reply.error
ncclient.operations.rpc.RPCError: {'type': 'protocol', 'tag': 'unknown-element', 'severity': 'error', 'info': 'filter\n\n', 'path': '\n /rpc/get-config\n ', 'message': None}

If I remove filter, ncclient runs without errors.
I'm guessing I'm doing something very simple, very wrong. If somebody can tell me what it is, much appreciated.

Br,
Heikki

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions