Skip to content

Commit d1836b2

Browse files
Delta456pujaganiharsha509
authored
py/test/selenium/webdriver/common/network.py: remove python 2 code (#14502)
* java/cookie: escape cookie values when required * add xss escaping * Fix formatting * use string builder * py/test/webdriver/network.py: remove python 2 code * remove java code * restore --------- Co-authored-by: Puja Jagani <[email protected]> Co-authored-by: Sri Harsha <[email protected]>
1 parent e455840 commit d1836b2

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

py/test/selenium/webdriver/common/network.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,7 @@
2525

2626
def get_interface_ip(ifname):
2727
def _bytes(value, encoding):
28-
try:
29-
return bytes(value, encoding) # Python 3
30-
except TypeError:
31-
return value # Python 2
28+
return bytes(value, encoding)
3229

3330
sckt = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
3431
return socket.inet_ntoa(

0 commit comments

Comments
 (0)