napalm-automation / napalm-junos

Apache License 2.0
22 stars 42 forks source link

Ignore warnings on commit #192

Closed mirceaulinic closed 7 years ago

mirceaulinic commented 7 years ago

If we are anyway ignoring warnings when loading changes into the candidate, when the user requires to ignore warnings, this can be applied also when committing.

Ping @sincerywaing - as you've introduced the optional arg in https://github.com/napalm-automation/napalm-junos/pull/180

coveralls commented 7 years ago

Coverage Status

Coverage remained the same at 83.612% when pulling 08c10930521f42accf43b24d125a96b72a61b64e on full-ignore into e6519c6dcde1e502db4b4ddb1d329ece05de7aea on develop.

sincerywaing commented 7 years ago

@mirceaulinic Just wondering when we get warning when committin? I've never seen one before. I may be wrong but I don't see warning arg in pyez?

sincerywaing commented 7 years ago

if commands can't be committed in it will throw Error exception instead of giving warning?

mirceaulinic commented 7 years ago

Just wondering when we get warning when committin? I've never seen one before. I may be wrong but I don't see warning arg in pyez?

Yes. See: https://github.com/Juniper/py-junos-eznc/blob/a7f1394d46210b6a0e981382c9380f134e3b25c0/lib/jnpr/junos/utils/config.py#L59-L83

if commands can't be committed in it will throw Error exception instead of giving warning?

Absolutely, in case of error it won't commit.

mirceaulinic commented 7 years ago

BTW: this is the behavior on the CLI -- if a certain warning is raised, it is just displayed on the screen, but the commit continues as normal.

sincerywaing commented 7 years ago

If this is the case, it's fine with me. Just need to document it I think.

Sent from my iPhone

On 21 Jul 2017, at 8:39 PM, Mircea Ulinic notifications@github.com wrote:

BTW: this is the behavior on the CLI -- if a certain warning is raised, it is just displayed on the screen, but the commit continues as normal.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.