Skip to content

Thermal manager fix message#29

Open
VadymYashchenko wants to merge 5 commits into
akokhan:newport_platform_apifrom
VadymYashchenko:thermal_manager_fix_message
Open

Thermal manager fix message#29
VadymYashchenko wants to merge 5 commits into
akokhan:newport_platform_apifrom
VadymYashchenko:thermal_manager_fix_message

Conversation

@VadymYashchenko
Copy link
Copy Markdown

@VadymYashchenko VadymYashchenko commented Dec 24, 2021

####Why I did it
I fixed LGTM message for Unnecessary delete statement in function and
Dec 23 10:30:37.956959 sonic INFO telemetry#supervisord 2021-12-23 10:30:37,956 INFO exited: dependent-startup (exit status 0; expected) Dec 23 10:31:05.949734 sonic WARNING pmon#thermalctld: High temperature warning: psu_driver-i2c-7-5a:psu1-temp1 current temperature 27.125C, high threshold -999.9C Dec 23 10:31:41.436897 sonic WARNING pmon#thermalctld: High temperature warning: psu_driver-i2c-7-5a:psu1-temp2 current temperature 38.0C, high threshold -999.9C

####How I did it
I reworked ThermalManager and Thermal classes

####How to verify it
platform_tests/api/test_chassis.py; platform_tests/api/test_thermal.py; acl/test_acl.py;

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106

Description for the changelog

A picture of a cute animal (not mandatory but encouraged)

Signed-off-by: Vadym Yashchenko <vadymx.yashchenko@intel.com>
Signed-off-by: Vadym Yashchenko <vadymx.yashchenko@intel.com>
Comment thread platform/barefoot/sonic-platform-modules-bfn-montara/sonic_platform/thermal.py Outdated
@akokhan akokhan removed the request for review from lguohan December 24, 2021 14:45
self.work()
self.__timer = Timer(self.__polling_thermal_time, self.start)
self.__timer.start()
if self.__running == True:
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should not be if not self.__running: ?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In this case it will be simple return without any action


# Thermal -> ThermalBase -> DeviceBase
class Thermal(ThermalBase):
_thresholds = {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will it work for Montara/Maveriks ?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure. For final solution about Montara to need testing and maybe additional records.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please do it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants