[sonic-cfggen] Fix init t1 config to align with YANG#21195
[sonic-cfggen] Fix init t1 config to align with YANG#21195qiluo-msft merged 8 commits intosonic-net:masterfrom
Conversation
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azpw ms_conflict |
This reverts commit 32692ea.
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run Azure.sonic-buildimage |
|
Commenter does not have sufficient privileges for PR 21195 in repo sonic-net/sonic-buildimage |
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
src/sonic-config-engine/tests/sample_output/t1-smartswitch.json
Outdated
Show resolved
Hide resolved
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
YANG validation check blocked by #21111 |
| # Ports in use should be admin up, unused ports default to admin down | ||
| if port in downlinks or port in uplinks: | ||
| data['PORT'][port].setdefault('admin_status', 'up') | ||
| data['PORT'][port].setdefault('speed', '50000') |
There was a problem hiding this comment.
There was a problem hiding this comment.
In general, port_config.ini always contains the speed column.
But the Unit test was using a port_config.ini doesn't contain speed https://github.com/sonic-net/sonic-buildimage/blob/master/src/sonic-config-engine/tests/t0-sample-port-config.ini
That's probably why we didn't hit yang issue for such long time.
@theasianpianist to review #Closed Refers to: src/sonic-config-engine/config_samples.py:192 in 051a6ee. [](commit_id = 051a6ee, deletion_comment = True) |
This change looks ok to me, did you have a specific concern? |
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Why I did it Improve the t1 config to align with YANG validation How I did it Add missing leafref and mandatory field to the config How to verify it YANG validation check on generated config
|
Re add 202411 to see if it generate PR automatically. |
|
Cherry-pick PR to 202411: #21641 |
Why I did it
Improve the t1 config to align with YANG validation
Work item tracking
How I did it
Add missing leafref and mandatory field to the config
How to verify it
YANG validation check on generated config
Which release branch to backport (provide reason below if selected)
Tested branch (Please provide the tested image version)
Description for the changelog
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)