From e0f5333d9ceb908cbfc5e25b88197de224c1cfe8 Mon Sep 17 00:00:00 2001 From: Mohamed Ghoneim Date: Thu, 28 Apr 2022 17:29:56 -0700 Subject: [PATCH] [SY] Adding exceptlionList to validation exception (#10699) #### Why I did it Adding exceptlionList to validation exception #### How I did it Check code. #### How to verify it Ran manually. - Run full config validation from a KVM - Print the thrown exception **Before** ``` Error: Data Loading Failed All Keys are not parsed in FEATURE dict_keys(['telemetry']) ``` **After** ``` Error: Data Loading Failed All Keys are not parsed in FEATURE dict_keys(['telemetry']) exceptionList:["'status'"] ``` #### Which release branch to backport (provide reason below if selected) - [ ] 201811 - [ ] 201911 - [ ] 202006 - [ ] 202012 - [ ] 202106 - [ ] 202111 #### Description for the changelog #### Link to config_db schema for YANG module changes #### A picture of a cute animal (not mandatory but encouraged) --- src/sonic-yang-mgmt/sonic_yang_ext.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sonic-yang-mgmt/sonic_yang_ext.py b/src/sonic-yang-mgmt/sonic_yang_ext.py index d43e529703..424e567f79 100644 --- a/src/sonic-yang-mgmt/sonic_yang_ext.py +++ b/src/sonic-yang-mgmt/sonic_yang_ext.py @@ -661,8 +661,8 @@ class SonicYangExtMixin: configC.keys()), debug=syslog.LOG_ERR, doPrint=True) self.sysLog(msg="exceptionList:{}".format(exceptionList), \ debug=syslog.LOG_ERR, doPrint=True) - raise(Exception("All Keys are not parsed in {}\n{}".format(table, \ - configC.keys()))) + raise(Exception("All Keys are not parsed in {}\n{}\nexceptionList:{}".format(table, \ + configC.keys(), exceptionList))) return