-
Notifications
You must be signed in to change notification settings - Fork 13
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
Netconf custom verifier #102
base: main
Are you sure you want to change the base?
Conversation
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.
Looks good overall. Just needs some housekeeping
@@ -11,10 +11,8 @@ | |||
__contact__ = '[email protected]' | |||
__copyright__ = 'Cisco Systems, Inc.' | |||
|
|||
from .count_verifier import CountVerifier |
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.
Was this removed intentionally? Seems strange to just get rid of it
from dataclasses import field, dataclass | ||
from google.protobuf import json_format | ||
|
||
# Import base classes. For non pyats installation you can use class provided within this module | ||
try: | ||
from genie.libs.sdk.triggers.blitz.verifiers import GnmiDefaultVerifier | ||
from genie.libs.sdk.triggers.blitz.verifiers import GnmiDefaultVerifier, NetconfDefaultVerifier |
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.
If this or GnmiDefaultVerifier
failed to import, then the entire file will break since you won't be able to subclass NetconfDefaultVerifier
. Is there something in the exception below you should be doing?
from genie.libs.sdk.triggers.blitz.rpcverify import OptFields | ||
|
||
@dataclass | ||
class MyCustomReturns(OptFields): |
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'd prefer something a bit more descriptive that MyCustomReturns
. Honestly, I'd even just prefer CustomReturns
over the current name
@KacperSzmitko would you please address Thomas's concerns? |
I did it in last commit |
@ThomasJRyan all the "housekeeping" has been addressed. Can you approve this? |
Thanks @ThomasJRyan . @omehrabi , @lsheikal , @yuekyang , need one more approver. |
Added custom netconf verifier example that i accidentally deleted here