We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Getting a route via ndb.routes[{"dst": "10.0.4.0/24"}] seems to be no longer working:
ndb.routes[{"dst": "10.0.4.0/24"}]
>>> ndb.routes[{"dst": "10.0.4.0/24"}] {'dst': '10.0.4.0/24'} {'dst': '10.0.4.0/24', 'target': 'localhost'} Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python3/dist-packages/pyroute2/ndb/auth_manager.py", line 69, in guard return f(obj, *argv, **kwarg) File "/usr/lib/python3/dist-packages/pyroute2/ndb/main.py", line 551, in __getitem__ ret = self.template(key, table) File "/usr/lib/python3/dist-packages/pyroute2/ndb/main.py", line 392, in template auth_managers=self.auth_managers) File "/usr/lib/python3/dist-packages/pyroute2/ndb/objects/route.py", line 525, in __init__ super(Route, self).__init__(*argv, **kwarg) File "/usr/lib/python3/dist-packages/pyroute2/ndb/objects/__init__.py", line 327, in __init__ raise KeyError('object does not exists') KeyError: 'object does not exists'
The same applies to ndb.routes.get({"dst": "10.0.4.0/24"}).
ndb.routes.get({"dst": "10.0.4.0/24"})
When using
>>> ndb.routes["10.0.4.0/24"] {'dst': '10.0.4.0', 'dst_len': 24, 'target': 'localhost'} {'multipath': [], 'metrics': {}, 'dst': '10.0.4.0', 'dst_len': 24, 'target': 'localhost', 'table': 254, 'tflags': 0, 'family': 2, 'tos': 0, 'scope': 253, 'oif': 4, 'priority': 0, 'via': '', 'newdst': '', 'src_len': 0, 'proto': 2, 'type': 1, 'flags': 0, 'src': None, 'iif': None, 'gateway': None, 'prefsrc': '10.0.4.15', 'protoinfo': None, 'flow': None, 'mark': None, 'pref': None, 'encap_type': None, 'route_id': None, 'gc_mark': None}
the route is found.
Tested with pyroute2 version 0.5.19 and 0.6.2.
pyroute2
0.5.19
0.6.2
Would be nice if this could be fixed and maybe patched for version 0.5 which we are using. 🙂
0.5
Thanks!
The text was updated successfully, but these errors were encountered:
Thanks, fixing!
Sorry, something went wrong.
ndb.objects.route: dst spec syntax fix
6aa174e
Bug-Url: #808
Thank you! 6aa174e seems to fix it. 😄 Any plans for a new release in the near future? Otherwise we will patch it on our own. 🙂
0.6.3 will be out on Monday with several minor fixes.
@mawiegand 0.6.3 is out
No branches or pull requests
Getting a route via
ndb.routes[{"dst": "10.0.4.0/24"}]
seems to be no longer working:The same applies to
ndb.routes.get({"dst": "10.0.4.0/24"})
.When using
the route is found.
Tested with
pyroute2
version0.5.19
and0.6.2
.Would be nice if this could be fixed and maybe patched for version
0.5
which we are using. 🙂Thanks!
The text was updated successfully, but these errors were encountered: