-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
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
Add PortAdmin "Write mem" support for H3C switches #1515
Conversation
This enables setting multiple varbinds in a single request
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've done a very cursory write-test from PortAdmin (not on an H3C, though). Have not tested Arnold. Since both subsystems using SNMP SET
operations are in your hands, I guess you are best qualified to assess any effects on these. I will assume read functionality is unaffected by this.
My only comment is therefore about the slight API change, noted inline.
python/nav/Snmp/pynetsnmp.py
Outdated
(TYPEMAP.keys(), data_type)) | ||
return value_type | ||
|
||
def set(self, query, data_type, value): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Although a variable named type
is generally a no-no, this is part of the API, and making the API inconsistent is a bigger no-no.
Either keep type
, or rename it to data_type
in the set method of all the other class Snmp
implementations - and ensure that any calling code that is using keyword arguments is updated.
Related issue #1411