[Edge-core][AS5812-54X] fixes : Inconsistent use of tabs and spaces in … #11766
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Signed-off-by: Roger Ho roger530_ho@edge-core.com
Why I did it
To startup as5812-platform-monitor.service fail.
Debug:
admin@sonic:~$ /usr/local/bin/accton_as5812_monitor.py
Traceback (most recent call last):
File "/usr/local/bin/accton_as5812_monitor.py", line 33, in
from as5812_54x.fanutil import FanUtil
File "/usr/lib/python3/dist-packages/as5812_54x/fanutil.py", line 138
val_file.close()
TabError: inconsistent use of tabs and spaces in indentation
How I did it
Replace tab with space
How to verify it
admin@sonic:~$ systemctl status as5812-platform-monitor.service
● as5812-platform-monitor.service - Accton AS5812-54X Platform Monitoring service
Loaded: loaded (/lib/systemd/system/as5812-platform-monitor.service; enabled; vendor preset: enabled)
Active: active (running) since Thu 2022-08-18 01:07:37 UTC; 2h 10min ago
Process: 25347 ExecStartPre=/usr/local/bin/accton_as5812_util.py install (code=exited, status=0/SUCCESS)
Main PID: 25357 (python)
Tasks: 1 (limit: 9477)
Memory: 7.5M
CGroup: /system.slice/as5812-platform-monitor.service
└─25357 python /usr/local/bin/accton_as5812_monitor.py
Which release branch to backport (provide reason below if selected)
--> customer requirement
--> customer requirement
Description for the changelog
Replace tab with space
Link to config_db schema for YANG module changes
N/A
A picture of a cute animal (not mandatory but encouraged)