Pushed as: a1ae934c28b5781b358a270fed77e35d23b205b0

-----Original Message-----
From: Bjorge, Erik C <erik.c.bjo...@intel.com> 
Sent: Wednesday, June 10, 2020 3:14 PM
To: devel@edk2.groups.io
Cc: Desimone, Ashley E <ashley.e.desim...@intel.com>; Desimone, Nathaniel L 
<nathaniel.l.desim...@intel.com>; Pandya, Puja <puja.pan...@intel.com>; Bret 
Barkelew <bret.barke...@microsoft.com>; Agyeman, Prince 
<prince.agye...@intel.com>
Subject: [edk2-staging/EdkRepo] [PATCH v2 2/3] EdkRepo: Adding backwards 
compatibility for old pin files

Older pin files used the invalid enable_submodule attribute.  This has been 
fixed for new pin files but we need to be able to support older pin files as 
well.

Cc: Ashley E Desimone <ashley.e.desim...@intel.com>
Cc: Nate DeSimone <nathaniel.l.desim...@intel.com>
Cc: Puja Pandya <puja.pan...@intel.com>
Cc: Bret Barkelew <bret.barke...@microsoft.com>
Cc: Prince Agyeman <prince.agye...@intel.com>
Cc: Erik Bjorge <erik.c.bjo...@intel.com>
Signed-off-by: Erik Bjorge <erik.c.bjo...@intel.com>
---
 edkrepo_manifest_parser/edk_manifest.py | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/edkrepo_manifest_parser/edk_manifest.py 
b/edkrepo_manifest_parser/edk_manifest.py
index adf6d52..00ad392 100644
--- a/edkrepo_manifest_parser/edk_manifest.py
+++ b/edkrepo_manifest_parser/edk_manifest.py
@@ -795,7 +795,11 @@ class _RepoSource():
             # If enableSubmodule is not set to True then default to False      
       self.enableSub = (element.attrib['enableSubmodule'].lower() == 'true')   
      except Exception:-            self.enableSub = False+            try:+    
            # Adding backwards compatibility with pin files that used incorrect 
attribute+                self.enableSub = 
(element.attrib['enable_submodule'].lower() == 'true')+            except 
Exception:+                self.enableSub = False          if self.branch is 
None and self.commit is None and self.tag is None:             raise 
KeyError(ATTRIBUTE_MISSING_ERROR)-- 
2.27.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#61538): https://edk2.groups.io/g/devel/message/61538
Mute This Topic: https://groups.io/mt/74807386/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to