Skip to content

Commit

Permalink
[BFN] Convert platform modules to python 3 (#6347)
Browse files Browse the repository at this point in the history
Fix syntax errors during xcvrd start with Python 3 daemons
  • Loading branch information
msosyak authored and lguohan committed Jan 5, 2021
1 parent 08ab275 commit f7bb635
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def qsfp_ports(self):

@property
def port_to_eeprom_mapping(self):
print "dependency on sysfs has been removed"
print("dependency on sysfs has been removed")
raise Exception()

def __init__(self):
Expand Down Expand Up @@ -88,8 +88,8 @@ def qsfp_presence_get(client):
try:
presence = thrift_try(qsfp_presence_get)
except Exception as e:
print e.__doc__
print e.message
print( e.__doc__)
print(e.message)

return presence

Expand Down Expand Up @@ -167,7 +167,7 @@ def get_transceiver_change_event(self, timeout=0):
elif timeout > 0:
timeout = timeout / float(1000) # Convert to secs
else:
print "get_transceiver_change_event:Invalid timeout value", timeout
print("get_transceiver_change_event:Invalid timeout value", timeout)
return False, {}

while forever or timeout > 0:
Expand Down

0 comments on commit f7bb635

Please # to comment.