Skip to content

Commit

Permalink
Merge pull request #1025 from vnitinv/sw-install-dep-warn
Browse files Browse the repository at this point in the history
DeprecationWarning added to sw.install
  • Loading branch information
dineshbaburam91 authored Apr 29, 2020
2 parents 75a5052 + 37f64ab commit dcb562c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/jnpr/junos/utils/sw.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
# Python 2.x
from urlparse import urlparse

import warnings
warnings.simplefilter('default', PendingDeprecationWarning)

# 3rd-party modules
from lxml.builder import E
Expand Down Expand Up @@ -797,6 +799,8 @@ def myprogress(dev, report):
* ``True`` when the installation is successful
* ``False`` otherwise
"""
warnings.warn("sw.install interface bool response is going to change "
"in next release.", PendingDeprecationWarning)
if issu is True and nssu is True:
raise TypeError(
'install function can either take issu or nssu not both')
Expand Down

0 comments on commit dcb562c

Please sign in to comment.