From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM04-BN8-obe.outbound.protection.outlook.com (NAM04-BN8-obe.outbound.protection.outlook.com [40.107.100.82]) by mx.groups.io with SMTP id smtpd.web11.1302.1612563256407228824 for ; Fri, 05 Feb 2021 14:14:17 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@amd.com header.s=selector1 header.b=Fz8SQ0St; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.107.100.82, mailfrom: garrett.kirkendall@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=TUB6O9frkQcqPfFaera60TZf9qS8QjY2/qu5GQlF4LWZGzb+aSBbWkkDu8ShQKtyG8ruxICJekzMr+DKZymRmAnVJ+1uBmSDKNcR0u6XS4S4Ezdhv8NglZp6fPbDWBSUghOjaer2Oc/ddx1TVkLTh1Hwk6PiRyV+uhNzFWfnrw4RvMndvAAdLbCCuAyhUPdfgtBAM7Anv36cb/Onw87kGXPhJL5AjCq4ECJUI9sHmdLHGAC+oyBlktfK1XeZlbaY1oBSqB0tXzm7TJKsX+6DbOpuJPjZ3m+Hr+fEgfjYi9CxpkP/ej9ulhh+OP/XvGz3eEkqP9GNL0rII2Qv8VJzTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YEYms6vBbSn4kTMVQEBgIjVYoEPETLhKlwoBftn23d0=; b=JIjmPZR2szGbLwjof5LnozTUl4yWwNkYl3cdtxS6lCRgSGdDs8wvVEFjeEmVae9RZb28JZkFGJ/LnPKN8rXeAhkMvRISZSjHrvL7xgtq7iBrMwZsonl4RbVZA4lIAQV4U7agOEMyBc5jtzLW48THhc4cwxNcWDpIQlxwA/qzsb1BI8GswlwwIizSgHHVrf2rvAGZfT+uvhB+iLFMkojdYQRbtCqxrxmqnKfVpLwcY4iOQhaiA3xN2p1FTdb11oMdXj8h6PdYwbjiFn5anoeIhn3GwHL2Ihhuf0ur2iO8myOlN7VjYVO4SUbsIBmNqi0zHcnlZ8GHpQtY9Eg0OBaong== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YEYms6vBbSn4kTMVQEBgIjVYoEPETLhKlwoBftn23d0=; b=Fz8SQ0StvCb1u99xtDJ7a7u1qc9cBFrK6tROMh3jH+hB1EVYc+Tk86CSKwNkXlhE73MQXHWJIJkolX0boGNB1XifmmNNWbJFQoHDYlC/T8G4PWJm2dBQOHstqfjVo17PJRDMQ/7+goH6oKMsNEl6S8gGXrOHDZwUT53v8+fQu2A= Received: from SA0PR12MB4525.namprd12.prod.outlook.com (2603:10b6:806:92::10) by SA0PR12MB4349.namprd12.prod.outlook.com (2603:10b6:806:98::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3825.24; Fri, 5 Feb 2021 22:14:14 +0000 Received: from SA0PR12MB4525.namprd12.prod.outlook.com ([fe80::c03c:710a:78e0:c8f5]) by SA0PR12MB4525.namprd12.prod.outlook.com ([fe80::c03c:710a:78e0:c8f5%4]) with mapi id 15.20.3825.020; Fri, 5 Feb 2021 22:14:14 +0000 From: "Kirkendall, Garrett" To: "Kinney, Michael D" , "devel@edk2.groups.io" , "Feng, Bob C" , Andrew Fish CC: "Pham, Tony Q" Subject: Re: [edk2-devel] EDK2 Thread-Topic: [edk2-devel] EDK2 Thread-Index: Adb7Pi/Ll9CinBmLQlK9K7kbFg35VAAEwhVQAACI2IAABuay4AAEBr/QABQ+4/AABB+1IAAK0etw Date: Fri, 5 Feb 2021 22:14:14 +0000 Message-ID: References: In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_ActionId=92543adf-f292-4b48-a51b-efbe969842a6;MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_ContentBits=0;MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_Enabled=true;MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_Method=Privileged;MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_Name=Non-Business;MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_SetDate=2021-02-05T22:11:46Z;MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=amd.com; x-originating-ip: [165.204.77.11] x-ms-publictraffictype: Email x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 7b4505bb-e3f8-4dad-a5fc-08d8ca235f5a x-ms-traffictypediagnostic: SA0PR12MB4349: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:7691; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: 5adfXQ1o7ZwlRLBlAMC4UuydjpbNjtXRJ0Biz1Wlaeom8CwxOrsOjgC6lF8Egd+qyttE00gGW26qyI8jpx4nFHUEblc2iBEnxE6NhR2EtW0S1udakTziCb5wEZ6RFXqHOIqrlFuNHfuCQ+EPxAsoKvwLZEpazz6tEgTRQuzgzSJO8EvUFQlcGjI20JiGHA4zkqSU0wynXatHUpiLljlIIn1hHWsBVXiEKWHa8XFSz3FVz61FD6/VQ2os99SISO2snf7AM/z34o+H8S32YwDP9o//r1yxNtdVNf1wJV91dgPnbBhq71jeBiDzM1ISPInVSfuFydNxjIwOxqamaTI4iTq9hgZ4nR0xProdHYPAt3YnKjvFZaQm5SwzDSp5W+DRl7VyMPvOu44xzrmQmNEr5y0SAxKVhFw5hrU04HC0/sXK941fHk2991SILRdThoq5TZETAl1R5i2pMwef5MVl+1oHsipPqolKprQHmMx2OnZXXOgUqc+R8Tqn0/j3z0BBNRE3LsM/lVaDJqGAofqkHEKlO4OrwM/mmsUaBs8Q2o1VZ71/8liAXFLaYf3WKm1heEsCd/+dxpPiL9ZqBa/eL7x+FtlpAUdL2MoQZL33Fhc= x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SA0PR12MB4525.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(346002)(376002)(136003)(396003)(39860400002)(366004)(86362001)(186003)(110136005)(71200400001)(66556008)(83380400001)(66476007)(316002)(76236003)(76116006)(66946007)(166002)(9686003)(66446008)(64756008)(478600001)(7696005)(55016002)(8676002)(33656002)(4326008)(6506007)(52536014)(5660300002)(8936002)(2906002)(26005)(53546011);DIR:OUT;SFP:1101; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?JWng5wbdd4SAEP3KqKrvku/ABYokqBV9Rp5+wOq1ZnfPgjLqIOC42iegU1g4?= =?us-ascii?Q?AFduCbI7hbPNgH4bI9C+DTG96wOcVAJPXiB8QNosSADg5EkCIgTRtdWIzgaD?= =?us-ascii?Q?HFhcy8G0+QymH1wYv/AyNT/QgIYH6uCmv9uQWD33UDH2HIAQl+Y64CDMo7IP?= =?us-ascii?Q?qM/IVXQs0BAQdvchUuBUPASDNeFBJqupMgzLG04T+q8z4ATqiIy2WH1RtSLC?= =?us-ascii?Q?FFKZHXeauQcA7B0SlA0W630ZDc7xjfQIF4dEmbf8OYtlvkyKePWI99wnP83z?= =?us-ascii?Q?kgc05hzOItq31hiVDvtCG3iend29hnUTQlmZa55TOFD8eN0u/McW3kUlv6+n?= =?us-ascii?Q?l2niZ3nGOXsL+S88Dd4cWz3E0EI+Ug/1Y8vuNswDA/TJdsx38N0wkmagUcRM?= =?us-ascii?Q?JnvpSIcZ5Ir+Mn0LtON7slmnAOs8Rb7/H27VCHh9PwXrNdgwfVoFuGtXkN4u?= =?us-ascii?Q?8z2eYKzLF9PnPxR6sbwWqpNO3iXsZArLFFzyZVq8FEyrbUIpwPL6ROSLnpZn?= =?us-ascii?Q?7RuC9HOmSY1TaX3p0Hazuz69ZLSnewO+y/Es04HnvBphi2Sk582YTHzQoUaa?= =?us-ascii?Q?0u2WYL4kdnGn/quCu5kk7fk1T2lnlCAeiP/4AmtHhyloLRE+1XpBO5FXHmuQ?= =?us-ascii?Q?7wXmcbugBG/Qh1gUJ4gVtpZNi/5ltTZfUrlBGE20iFPwMCOAwucwpjp9gx8s?= =?us-ascii?Q?XqUxTco9nb8me7wq5l9zE83GCNRVWVtz2eGWmm8+ntJtf84WeFCBE9M2ILHE?= =?us-ascii?Q?TP1xJ9u3P443w9gGxYs6Nq1SMcSOd68crMmIT2Yoy1HBGoKKNQOfWaoLtUAy?= =?us-ascii?Q?EVU/ME+t3IqtcPundqF+WskTHnKvcMsslygTcjzMrz3iQZm8bKg3ESXw/f7K?= =?us-ascii?Q?xo5dRqJRo/N7FqeFMB40dqFxn06t+UilP9u81u3DuhccMwSSbggNFiDM0HpP?= =?us-ascii?Q?pG29XdEpiZ+3gpVsjCET1D6d8w1zXCl/t9PK1LSiASYdKO5hyVUG7Y/IdqeU?= =?us-ascii?Q?bOsclAEaX3kWqxqsAKeOWEhpCviHBRavUBP2e6QZq3hz1eu8oNJBa5ou4lPW?= =?us-ascii?Q?bpotywLQbja3SPOpZOijVHBW3Bp+Riykg5cjfVKzF3cGGgJKE6vFgjuI1MD0?= =?us-ascii?Q?9A2rWGUV0ABqzobLlVDJ1/uW0IZGqQFKGmdK5M5xwxlIdQ7hbbyJrGT5Ckuv?= =?us-ascii?Q?D1ZeCHOoudv/nk54SiVTgjQoDlaJGawmrqz6Gd/m10YU3VfEcU6Bq5GBSe09?= =?us-ascii?Q?4ixQsWqtFLCLt8/7lOv8ncFUYBNmUA987Z2tI70cqLPlillveoSjDkFjAIyt?= =?us-ascii?Q?kxu3+M8agJj1B+Epg/KnuKRe?= x-ms-exchange-transport-forked: True MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SA0PR12MB4525.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7b4505bb-e3f8-4dad-a5fc-08d8ca235f5a X-MS-Exchange-CrossTenant-originalarrivaltime: 05 Feb 2021 22:14:14.4162 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: bNJlvje9oIsNw4Yps5KvHKWQ9D2CkgTqNLyF9z6vyRcptC6hEY8U3fh2Tbc04ZXrXiYLKMv4CRzgrLxjP9VvYw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA0PR12MB4349 Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_SA0PR12MB4525F14686F5950CE6AC5D6F85B29SA0PR12MB4525namp_" --_000_SA0PR12MB4525F14686F5950CE6AC5D6F85B29SA0PR12MB4525namp_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable I found a couple of extensions for Visual Studio Code that will highlight b= ad characters. "Highlight Dodgy Characters" seems to do the trick. Sorry about that AMD Official Use Only thing. The wonders of modern email= apps! Garrett Kirkendall SMTS Firmware Engineer 7171 Southwest Parkway, Austin, TX 78735 USA AMD facebook | amd.com From: Kinney, Michael D Sent: Friday, February 5, 2021 11:03 AM To: Kirkendall, Garrett ; devel@edk2.groups.io= ; Feng, Bob C ; Andrew Fish ; Kinney= , Michael D Cc: Pham, Tony Q Subject: RE: [edk2-devel] EDK2 [AMD Official Use Only - Internal Distribution Only] [CAUTION: External Email] One I know the file path, I usually use a Notepad++ feature: Search-> Find Chars In Range-> Non ASCII Mike From: Kirkendall, Garrett > Sent: Friday, February 5, 2021 7:11 AM To: devel@edk2.groups.io; Feng, Bob C >; Kinney, Michael D >; Andrew Fish > Cc: Pham, Tony Q > Subject: RE: [edk2-devel] EDK2 [AMD Official Use Only - Internal Distribution Only] 0x9d is one of those pesky "smart quotes" many applications love to use. = These are the double quote or single quote characters that slant left and r= ight instead of the straight up and down like the ASCII versions. They can be very hard to track down in a source file because a lot of edit= ors have very subtle slants to the smart quotes. This usually happens when you copy from one app like MS Word and paste int= o your source file. Garrett Kirkendall SMTS Firmware Engineer 7171 Southwest Parkway, Austin, TX 78735 USA AMD facebook | amd.com From: devel@edk2.groups.io > On Behalf Of Bob Feng via groups.io Sent: Thursday, February 4, 2021 11:40 PM To: devel@edk2.groups.io; Kinney, Michael D <= michael.d.kinney@intel.com>; Andrew Fish= > Cc: Pham, Tony Q > Subject: Re: [edk2-devel] EDK2 [CAUTION: External Email] Tony, This build failure should be caused by one of your c or header files have = non-ascii characters. You may need to change the basetools' code to see which file has non-ascii= characters Change C:\edk2\BaseTools\Source\Python\AutoGen\StrGather.py, Line 536 except: EdkLogger.error("UnicodeStringGather", AUTOGEN_ERROR, "SearchS= tring: Error while processing file", File=3DFile, RaiseError=3DFalse) raise to except: EdkLogger.error("UnicodeStringGather", AUTOGEN_ERROR, "SearchS= tring: Error while processing file", File=3DFile, RaiseError=3DTrue) Thanks, Bob From: devel@edk2.groups.io > On Behalf Of Michael D Kinney Sent: Friday, February 5, 2021 11:30 AM To: Andrew Fish >; edk2-devel-grou= ps-io >; Kinney, Michael = D > Cc: Pham, Tony Q > Subject: Re: [edk2-devel] EDK2 Hi Andrew, If the character is part of the code (not a comment), the ignoring the cod= ec error could silently produce the incorrect FW behavior. I prefer a failure with a correct identification of the file/line # so the= file can be fixed. The EDK II CI checks will not allow files in with these types of issues. Mike From: Andrew Fish > Sent: Thursday, February 4, 2021 4:11 PM To: edk2-devel-groups-io >; Kinney, Michael D > Cc: Pham, Tony Q > Subject: Re: [edk2-devel] EDK2 On Feb 4, 2021, at 3:58 PM, Michael D Kinney > wrote: Hi Tony, I suspect that one of your UNI files being processed by StrGather has an i= nvalid Unicode character in it. Can you review the UNI files in the module= that is being build when this error is generated? I would be better if this code identified the file/line number with the is= sue, so that would be a good Bugzilla to enter. Mike, I hit something like this too writing some Python. I think I ended up tell= ing the codec to ignore errors, so that might be another option? This I thi= nk the issue I saw was in C code. Thanks, Andrew Fish Mike From: devel@edk2.groups.io > On Behalf Of Pham, Tony Q Sent: Thursday, February 4, 2021 1:39 PM To: devel@edk2.groups.io Subject: [edk2-devel] EDK2 Hi, I have a problem with build.py (Python 3.9.1 on win32) Traceback (most recent call last): File "C:\edk2\BaseTools\Source\Python\build\build.py", line 2635, in Mai= n MyBuild.Launch() File "C:\edk2\BaseTools\Source\Python\build\build.py", line 2433, in Lau= nch self._BuildModule() File "C:\edk2\BaseTools\Source\Python\build\build.py", line 1895, in _Bu= ildModule Ma.CreateCodeFile(True) File "C:\edk2\BaseTools\Source\Python\AutoGen\ModuleAutoGen.py", line 18= 32, in CreateCodeFile for File in self.AutoGenFileList: File "C:\edk2\BaseTools\Source\Python\Common\caching.py", line 28, in __= get__ Value =3D obj.__dict__[self._function.__name__] =3D self._function(obj= ) File "C:\edk2\BaseTools\Source\Python\AutoGen\ModuleAutoGen.py", line 98= 3, in AutoGenFileList GenC.CreateCode(self, AutoGenC, AutoGenH, StringH, AutoGenUniIdf, UniS= tringBinBuffer, StringIdf, AutoGenUniIdf, IdfGenBinBuffer) File "C:\edk2\BaseTools\Source\Python\AutoGen\GenC.py", line 2044, in Cr= eateCode CreateUnicodeStringCode(Info, AutoGenC, StringH, UniGenCFlag, UniGenBi= nBuffer) File "C:\edk2\BaseTools\Source\Python\AutoGen\GenC.py", line 1706, in Cr= eateUnicodeStringCode Header, Code =3D GetStringFiles(Info.UnicodeFileList, SrcList, IncList= , Info.IncludePathList, ['.uni', '.inf'], Info.Name, CompatibleMode, ShellM= ode, UniGenCFlag, UniGenBinBuffer, FilterInfo) File "C:\edk2\BaseTools\Source\Python\AutoGen\StrGather.py", line 563, i= n GetStringFiles Uni =3D SearchString(Uni, sorted (FileList), IsCompatibleMode) File "C:\edk2\BaseTools\Source\Python\AutoGen\StrGather.py", line 532, i= n SearchString for Line in Lines: File "C:\Users\tqpham\AppData\Local\Programs\Python\Python39\lib\encodin= gs\cp1252.py", line 23, in decode return codecs.charmap_decode(input,self.errors,decoding_table)[0] UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d in position 545= 7: character maps to - Failed - Build end time: 13:36:22, Feb.04 2021 Build total time: 00:00:02 --_000_SA0PR12MB4525F14686F5950CE6AC5D6F85B29SA0PR12MB4525namp_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

I found a couple of extensions for Visual Studio Co= de that will highlight bad characters.  "Highlight Dodgy Characte= rs" seems to do the trick.

 

Sorry about that AMD Official Use Only thing. = The wonders of modern email apps!

 

Garrett Kirkendall
SMTS Firmware Engineer
7171 Southwest Parkway, Austin, TX 78735 USA
AMD   facebook  |  amd.com

 

From: Kinney, Michael D <michael.d.kinney= @intel.com>
Sent: Friday, February 5, 2021 11:03 AM
To: Kirkendall, Garrett <Garrett.Kirkendall@amd.com>; devel@e= dk2.groups.io; Feng, Bob C <bob.c.feng@intel.com>; Andrew Fish <af= ish@apple.com>; Kinney, Michael D <michael.d.kinney@intel.com>
Cc: Pham, Tony Q <tony.q.pham@intel.com>
Subject: RE: [edk2-devel] EDK2

 

[AMD Official Use Only - Internal Distribution Only]=

 

[CAUTION: External Email]

One I know the file path, I usually use a Notepad++= feature:

 

        &nb= sp;     Search-> Find Chars In Range-> Non ASCII<= o:p>

 

Mike

 

From: Kirkendall, Garrett <Garrett.Kirkendall@amd.com>
Sent: Friday, February 5, 2021 7:11 AM
To: devel@edk2.groups.io; Feng, Bob C <bob.c.feng@intel= .com>; Kinney, Michael D <michael.d.kinney@intel.com>; Andrew Fish <afish@apple.com>
Cc: Pham, Tony Q <tony.= q.pham@intel.com>
Subject: RE: [edk2-devel] EDK2

 

[AMD Official Use Only - Internal Distribution Only]=

 

0x9d is one of those pesky "smart quotes"= many applications love to use.  These are the double quote or single = quote characters that slant left and right instead of the straight up and d= own like the ASCII versions.

They can be very hard to track down in a source fil= e because a lot of editors have very subtle slants to the smart quotes.

This usually happens when you copy from one app lik= e MS Word and paste into your source file.

 

Garrett Kirkendall
SMTS Firmware Engineer
7171 Southwest Parkway, Austin, TX 78735 USA
AMD   facebook  |  amd.com

 

From: devel@edk2.groups.io <deve= l@edk2.groups.io> On Behalf Of Bob Feng via groups.io
Sent: Thursday, February 4, 2021 11:40 PM
To: devel@edk2.groups.io; Kinney, Michael D <mich= ael.d.kinney@intel.com>; Andrew Fish <afish@apple.com>
Cc: Pham, Tony Q <tony.= q.pham@intel.com>
Subject: Re: [edk2-devel] EDK2

 

[CAUTION: External Email]

Tony,

 

This build failure should be caused by one of your = c or header files have non-ascii characters.

 

You may need to change the basetools’ code to= see which file has non-ascii characters

 

Change C:\edk2\BaseTools\Source\Python\AutoGen\StrG= ather.py, Line 536

     =    ex= cept:=

     =        EdkLogger.error("UnicodeStri= ngGather", AUTOGEN_ERROR, "SearchString: Error while processing file"= , File=3DFile, RaiseError=3DFalse)

          =   ra= ise

to

   &nb= sp;            except:

     =        EdkLogger.error("UnicodeStri= ngGather", AUTOGEN_ERROR, "SearchString: Error while processing file"= , File=3DFile, RaiseError=3DTrue)

 

 

 

Thanks,

Bob

 

From: devel@edk2.groups.io <deve= l@edk2.groups.io> On Behalf Of Michael D Kinney
Sent: Friday, February 5, 2021 11:30 AM
To: Andrew Fish <afish@apple.= com>; edk2-devel-groups-io <devel@edk2.groups.io>; Kinney, Michael D <michael.d.kinney@intel.com>
Cc: Pham, Tony Q <tony.= q.pham@intel.com>
Subject: Re: [edk2-devel] EDK2

 

Hi Andrew,

 

If the character is part of the code (not a comment= ), the ignoring the codec error could silently produce the incorrect FW beh= avior.

 

I prefer a failure with a correct identification of= the file/line # so the file can be fixed.

 

The EDK II CI checks will not allow files in with t= hese types of issues.

 

Mike

 

 

 

From: Andrew Fish <afish@apple.com>
Sent: Thursday, February 4, 2021 4:11 PM
To: edk2-devel-groups-io <devel@edk2.groups.io>; Kinney, Michael D <michael.d.kinney@intel.com>
Cc: Pham, Tony Q <tony.= q.pham@intel.com>
Subject: Re: [edk2-devel] EDK2

 

 

 

On Feb 4, 2021, at 3:58 PM, Michael D Kinney <michael.d.kinney@intel.com&= gt; wrote:

 

Hi Tony,

 

I suspect that one of your UNI files being processe= d by StrGather has a= n invalid Unicode character in it.  Can you review the UNI files in the module that is being build when this erro= r is generated?

 

I would be better if this code identified the file/= line number with the issue, so that would be a good Bugzilla to enter.=

 

 

Mike,

 

I hit something like this too writing some Python. = I think I ended up telling the codec to ignore errors, so that might be ano= ther option? This I think the issue I saw was in C code. 

 

Thanks,

 

Andrew Fish

 

Mike

 

From:&= nbsp;devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Pham, Ton= y Q
Sent: Thursday, F= ebruary 4, 2021 1:39 PM
To: devel@edk2.groups.= io
Subject: [edk2-de= vel] EDK2

 

Hi,

 

I have a problem with build.py

 

(Python 3.9.1 on win32) Traceback (most recent call= last):

  File "C:\edk2\BaseTools\Source\Python\b= uild\build.py", line 2635, in Main

    MyBuild.Launch()

  File "C:\edk2\BaseTools\Source\Python\b= uild\build.py", line 2433, in Launch

    self._BuildModule()

  File "C:\edk2\BaseTools\Source\Python\b= uild\build.py", line 1895, in _BuildModule

    Ma.CreateCodeFile(True)

  File "C:\edk2\BaseTools\Source\Python\A= utoGen\ModuleAutoGen.py", line 1832, in CreateCodeFile

    for File in self.AutoGenFileList= :

  File "C:\edk2\BaseTools\Source\Python\C= ommon\caching.py", line 28, in __get__

    Value =3D obj.__dict__[self._fun= ction.__name__] =3D self._function(obj)

  File "C:\edk2\BaseTools\Source\Python\A= utoGen\ModuleAutoGen.py", line 983, in AutoGenFileList

    GenC.CreateCode(self, AutoGenC, = AutoGenH, StringH, AutoGenUniIdf, UniStringBinBuffer, StringIdf, AutoGenUni= Idf, IdfGenBinBuffer)

  File "C:\edk2\BaseTools\Source\Python\A= utoGen\GenC.py", line 2044, in CreateCode

    CreateUnicodeStringCode(Info, Au= toGenC, StringH, UniGenCFlag, UniGenBinBuffer)

  File "C:\edk2\BaseTools\Source\Python\A= utoGen\GenC.py", line 1706, in CreateUnicodeStringCode

    Header, Code =3D GetStringFiles(= Info.UnicodeFileList, SrcList, IncList, Info.IncludePathList, ['.uni', '.in= f'], Info.Name, CompatibleMode, ShellMode, UniGenCFlag, UniGenBinBuffer, Fi= lterInfo)

  File "C:\edk2\BaseTools\Source\Python\A= utoGen\StrGather.py", line 563, in GetStringFiles

    Uni =3D SearchString(Uni, sorted= (FileList), IsCompatibleMode)

  File "C:\edk2\BaseTools\Source\Python\A= utoGen\StrGather.py", line 532, in SearchString

    for Line in Lines:

  File "C:\Users\tqpham\AppData\Local\Pro= grams\Python\Python39\lib\encodings\cp1252.py", line 23, in decode

    return codecs.charmap_decode(inp= ut,self.errors,decoding_table)[0]

UnicodeDecodeError: 'charmap' codec can't decode by= te 0x9d in position 5457: character maps to <undefined>

 

 

- Failed -

Build end time: 13:36:22, Feb.04 2021

Build total time: 00:00:02

 

--_000_SA0PR12MB4525F14686F5950CE6AC5D6F85B29SA0PR12MB4525namp_--