sonic-utilities icon indicating copy to clipboard operation
sonic-utilities copied to clipboard

Make PFC commands use a class

Open bktsim-arista opened this issue 1 year ago • 7 comments

What I did

This change puts contents originally in pfc/main.py into a class, to support the usage of the multi-asic helper in a future change. This change is required, as multi-asic helper being used expects members self.config_db and self.db to exist when a function with the decorator run_on_multi_asic is called. The multi-asic class helper will be used to add multi-asic support to pfc commands in a following pull request.

This is a part of the set of changes being pushed for https://github.com/sonic-net/sonic-buildimage/issues/15148

How I did it

Moved contents of PFC commands into a class. There are no functional changes.

bktsim-arista avatar Nov 30 '23 17:11 bktsim-arista

/azpw run Azure.sonic-utilities

arista-nwolfe avatar Jan 16 '24 21:01 arista-nwolfe

/azpw run

wenyiz2021 avatar Jan 16 '24 22:01 wenyiz2021

/azpw run Azure.sonic-utilities

arlakshm avatar Jan 17 '24 18:01 arlakshm

/azp run Azure.sonic-utilities

arlakshm avatar Jan 17 '24 18:01 arlakshm

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Jan 17 '24 18:01 azure-pipelines[bot]

/azp run

vmittal-msft avatar Mar 25 '24 20:03 vmittal-msft

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Mar 25 '24 20:03 azure-pipelines[bot]

Because of the conversion of global methods to class methods, there are lots of white space changes. The best way to review this PR is to ignore whitespace.

kenneth-arista avatar May 28 '24 06:05 kenneth-arista

@bktsim-arista Please file a direct PR to 202405 branch to address the conflict.

bingwang-ms avatar Sep 06 '24 21:09 bingwang-ms

@bktsim-arista Please file a direct PR to 202405 branch to address the conflict.

There's no need to cherry-pick this PR into 202405 because commit 64473080 is already included. 😄 Can you change the label to already included in 202405?

kenneth-arista avatar Sep 09 '24 03:09 kenneth-arista