Skip to content

Commit

Permalink
Add yang_config_validation in device_info (#11715)
Browse files Browse the repository at this point in the history
Why I did it
Put yang_config_validation in common lib and make it reusabe

How I did it
Move the definition to device_info.py
  • Loading branch information
wen587 authored Aug 17, 2022
1 parent abda50c commit 5846cdd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/sonic-py-common/sonic_py_common/device_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -403,6 +403,10 @@ def get_chassis_info():

return chassis_info_dict


def is_yang_config_validation_enabled(config_db):
return get_localhost_info('yang_config_validation', config_db) == 'enable'

#
# Multi-NPU functionality
#
Expand Down

0 comments on commit 5846cdd

Please sign in to comment.