Support Grouping translation in YANG Models.#8318
Merged
arlakshm merged 1 commit intosonic-net:masterfrom Sep 30, 2021
Merged
Conversation
20787ac to
741a59d
Compare
741a59d to
faae0c3
Compare
Member
Author
|
@jleveque : can you help in running the Azure pipeline again, seems like temporary failure. Thanks a lot. |
Member
Author
|
@qiluo-msft, @renukamanavalan : not sure, who is the right person to review this PR. |
Collaborator
|
@arlakshm Could you help review? |
Changes: -- pre Process Grouping section from all yang models, so it can be used from any yang model. -- add jsondiff in setup.py, it is useful for test debugging in case of failures. -- use 'stypes' instead of head. -- pass config DB table name in _createLeafDict(). -- added test config for grouping. -- white spaces changes . Note: Changes are done in the way that we can add supoort for other Generic YANG statement easily for tranlation. Signed-off-by: Praveen Chaudhary [email protected]
faae0c3 to
c2dc42f
Compare
Member
Author
|
Rebased to rerun Azure Pipeline |
Collaborator
|
PR owner could use |
arlakshm
reviewed
Aug 25, 2021
ghooo
added a commit
to sonic-net/sonic-utilities
that referenced
this pull request
Feb 23, 2022
#### What I did Fixes #2041 Supporting groupings during `config-db path` <-> `config-yang xpath` translation This mimics the `config-db` <-> `config-yang` translation as added by sonic-net/sonic-buildimage#8318 #### How I did it Handled groupings of leaf commands only as that's what is supported in sonic-yang-mgmt #### How to verify it unit-test #### Previous command output (if the output of a command-line utility has changed) #### New command output (if the output of a command-line utility has changed)
malletvapid23
added a commit
to malletvapid23/Sonic-Utility
that referenced
this pull request
Aug 3, 2023
#### What I did Fixes #2041 Supporting groupings during `config-db path` <-> `config-yang xpath` translation This mimics the `config-db` <-> `config-yang` translation as added by sonic-net/sonic-buildimage#8318 #### How I did it Handled groupings of leaf commands only as that's what is supported in sonic-yang-mgmt #### How to verify it unit-test #### Previous command output (if the output of a command-line utility has changed) #### New command output (if the output of a command-line utility has changed)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
[sonic_yang_ext.py]: Support Grouping translation in YANG Models.
Changes:
-- pre Process Grouping section from all yang models, so it can be used
from any yang model.
-- add jsondiff in setup.py, it is useful for test debugging in case of
failures.
-- use 'stypes' instead of head.
-- pass config DB table name in _createLeafDict().
-- added test config for grouping.
-- white spaces changes.
Note: Changes are done in the way that we can add supoort for other
Generic YANG statement easily for tranlation.
Signed-off-by: Praveen Chaudhary [email protected]
Why I did it
Need to support Grouping translation in YANG Models.
How I did it
Changes:
-- pre Process Grouping section from all yang models, so it can be used
from any yang model. File: src/sonic-yang-mgmt/sonic_yang_ext.py
-- add jsondiff in setup.py, it is useful for test debugging in case of
failures.
-- use 'stypes' instead of head.
-- pass config DB table name in _createLeafDict().
-- added test config for grouping.
-- white spaces changes.
How to verify it
Added Build Time Tests: File: src/sonic-yang-models/tests/files/sample_config_db.json
Build the PKG.
Which release branch to backport (provide reason below if selected)
Description for the changelog
A picture of a cute animal (not mandatory but encouraged)