Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[generic-config-updater] Cropping current/target config before sorting #1831

Merged

Conversation

ghooo
Copy link
Contributor

@ghooo ghooo commented Sep 18, 2021

What I did

Fixing issue #1830

How I did it

Problem we consume the function loadData from sonic-yang-mgmt pkg that always crops tables without YANG models from configdb json object. It does it as a side-effect and is not an expected outcome of the function.

The fix here is to crop the current/target tables before doing any sorting, this way gurantee we avoid this bug. I think the better soln is to fix sonic-yang-mgmt pkg. Will look into this more next week.

How to verify it

Run the command in the issue, it will result in the expected outcome

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)

TODO: add unit-tests

@qiluo-msft
Copy link
Contributor

You mentioned "TODO: add unit-tests". Will it happen in this PR?

@ghooo ghooo merged commit 9232c54 into sonic-net:master Oct 8, 2021
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.

2 participants