-
Notifications
You must be signed in to change notification settings - Fork 175
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[sonic_eeprom] Make compatible with Python 2 and 3 #127
Conversation
I'll build an image with this change and try it out on one of our platforms. |
Testing showed a python3 compatibility issue in our code but not related to this change. |
@keboliu: Have you had a chance to test this change on your platforms? |
I'll try to find some time to test. |
@keboliu: Have you had a chance to test this change on your platforms? |
Python3 fixes for Arista are available in sonic-net/sonic-buildimage#5736 |
Sorry for the late response, I should be able to do it tomorrow. |
Enhance chassisd to monitor midplane status of the cards in modular chassis HLD: sonic-net/SONiC#646 -What I did Add monitoring of the midplane or internal ethernet network between supervisor and line-card modules. -How I did it Along with status monitoring, also monitor the midplane reachability between supervisor and modules. It updates the STATE_DB with the status information. 'show chassis-modules midplane-status' will read from the STATE_DB
The
string
type has changed between Python 2 and 3. Therefore, the Python 3 version of this library is broken.This PR changes the data type of the raw EEPROM data to a
bytearray
, which is treated the same in both Python 2 and Python 3, and is technically a more appropriate data type for the raw bytes anyway.However, this PR could cause issues if any vendors are overriding the
read_eeprom_bytes()
orread_eeprom()
functions and returning astring
. Any vendors doing so will need to refactor their implementation to return abytearray
instead.