File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change 249
249
'pexpect>=4.8.0' ,
250
250
'semantic-version>=2.8.5' ,
251
251
'prettyprinter>=0.18.0' ,
252
- 'pyroute2>=0.5.14, <0.6.1 ' ,
252
+ 'pyroute2==0.7.12 ' ,
253
253
'requests>=2.25.0, <=2.31.0' ,
254
254
'tabulate==0.9.0' ,
255
255
'toposort==1.6' ,
Original file line number Diff line number Diff line change 3
3
4
4
import click
5
5
import netifaces
6
- import pyroute2
7
6
from natsort import natsorted
8
7
from sonic_py_common import multi_asic , device_info
9
8
from utilities_common import constants
@@ -170,6 +169,7 @@ def multi_asic_args(parser=None):
170
169
return parser
171
170
172
171
def multi_asic_get_ip_intf_from_ns (namespace ):
172
+ import pyroute2
173
173
if namespace != constants .DEFAULT_NAMESPACE :
174
174
pyroute2 .netns .pushns (namespace )
175
175
interfaces = natsorted (netifaces .interfaces ())
@@ -181,6 +181,7 @@ def multi_asic_get_ip_intf_from_ns(namespace):
181
181
182
182
183
183
def multi_asic_get_ip_intf_addr_from_ns (namespace , iface ):
184
+ import pyroute2
184
185
if namespace != constants .DEFAULT_NAMESPACE :
185
186
pyroute2 .netns .pushns (namespace )
186
187
ipaddresses = netifaces .ifaddresses (iface )
You can’t perform that action at this time.
0 commit comments