From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from rn-mailsvcp-ppex-lapp24.apple.com (rn-mailsvcp-ppex-lapp24.apple.com [17.179.253.38]) by mx.groups.io with SMTP id smtpd.web08.14819.1633018626551136466 for ; Thu, 30 Sep 2021 09:17:06 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@apple.com header.s=20180706 header.b=F/Ni4HF3; spf=pass (domain: apple.com, ip: 17.179.253.38, mailfrom: afish@apple.com) Received: from pps.filterd (rn-mailsvcp-ppex-lapp24.rno.apple.com [127.0.0.1]) by rn-mailsvcp-ppex-lapp24.rno.apple.com (8.16.1.2/8.16.1.2) with SMTP id 18UGCR2n021399; Thu, 30 Sep 2021 09:17:06 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=apple.com; h=from : content-type : mime-version : subject : date : references : to : in-reply-to : message-id; s=20180706; bh=IXIYNEbuAHh+LvkRinQc+c9AY/Ajwos2qppdWUCoWa0=; b=F/Ni4HF32Zz/Oj5IJzsuUmtm3scMlOzmUepXhA9iU9PwQvmC7XPLPDY4d7+nYwKxgw5w 3ycjLv/Sa/leDC1gZjBiQI7VnRpeDIfcJn+efBKWbeVYcNRakB2bKQFZNKXxV9/53y4h CvsdPPlmteiZt/ni6kf/uxCIfaPjSbEgdLJhA6ewiqWMPZCzr62MRWHTp/mOjIyJhX9S JzP+fdsQQhYWE9C6K1UYkAFpL+CbPQzRSwRtVBouBVEWOYoFAUYAR9rpFVQbwpZYK4Wj da5tc3Ixdfaa9N2DsrarPqNBF5h9JdMIMFQrLcLAUEoOHLSO6wB7N3okm0G8KeSfkUPu VQ== Received: from rn-mailsvcp-mta-lapp03.rno.apple.com (rn-mailsvcp-mta-lapp03.rno.apple.com [10.225.203.151]) by rn-mailsvcp-ppex-lapp24.rno.apple.com with ESMTP id 3ba1cbnex5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO); Thu, 30 Sep 2021 09:17:06 -0700 Received: from rn-mailsvcp-mmp-lapp01.rno.apple.com (rn-mailsvcp-mmp-lapp01.rno.apple.com [17.179.253.14]) by rn-mailsvcp-mta-lapp03.rno.apple.com (Oracle Communications Messaging Server 8.1.0.9.20210415 64bit (built Apr 15 2021)) with ESMTPS id <0R0900ZBW98GTX20@rn-mailsvcp-mta-lapp03.rno.apple.com>; Thu, 30 Sep 2021 09:17:04 -0700 (PDT) Received: from process_milters-daemon.rn-mailsvcp-mmp-lapp01.rno.apple.com by rn-mailsvcp-mmp-lapp01.rno.apple.com (Oracle Communications Messaging Server 8.1.0.9.20210415 64bit (built Apr 15 2021)) id <0R090000097PXC00@rn-mailsvcp-mmp-lapp01.rno.apple.com>; Thu, 30 Sep 2021 09:17:04 -0700 (PDT) X-Va-A: X-Va-T-CD: eaaf8ab07f047079995688c5662e41ea X-Va-E-CD: 31eb8097b4bff8fc0821441e5a566106 X-Va-R-CD: 036f3fc861799b276ddc7e6246f45ea8 X-Va-CD: 0 X-Va-ID: 0ab5564a-9e4a-42f6-88a8-22e5e52add0f X-V-A: X-V-T-CD: eaaf8ab07f047079995688c5662e41ea X-V-E-CD: 31eb8097b4bff8fc0821441e5a566106 X-V-R-CD: 036f3fc861799b276ddc7e6246f45ea8 X-V-CD: 0 X-V-ID: 17a24318-ade0-4f38-9931-de50f83a17bf X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391,18.0.790 definitions=2021-09-30_05:2021-09-30,2021-09-30 signatures=0 Received: from [17.235.1.5] (unknown [17.235.1.5]) by rn-mailsvcp-mmp-lapp01.rno.apple.com (Oracle Communications Messaging Server 8.1.0.9.20210415 64bit (built Apr 15 2021)) with ESMTPSA id <0R09001ML98FXU00@rn-mailsvcp-mmp-lapp01.rno.apple.com>; Thu, 30 Sep 2021 09:17:04 -0700 (PDT) From: "Andrew Fish" MIME-version: 1.0 (Mac OS X Mail 14.0 \(3654.20.0.2.1\)) Subject: Re: [edk2-devel] error C0DE: Tools code failure Date: Thu, 30 Sep 2021 09:17:02 -0700 References: To: edk2-devel-groups-io , piyush.kumar.jain@intel.com In-reply-to: Message-id: X-Mailer: Apple Mail (2.3654.20.0.2.1) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391,18.0.790 definitions=2021-09-30_05:2021-09-30,2021-09-30 signatures=0 Content-type: multipart/alternative; boundary="Apple-Mail=_39589A42-4A9A-4429-A45E-09FE1FAA547B" --Apple-Mail=_39589A42-4A9A-4429-A45E-09FE1FAA547B Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Are you using Python 2.7? Try using Python 3.* It looks like array.fromstring() got renamed to array.frombytes() in Python= 3.2, so I=E2=80=99m guessing you are using Python 2.7? Thanks, Andrew Fish > On Sep 30, 2021, at 1:19 AM, Kumar Jain, Piyush wrote: >=20 > Traceback (most recent call last): > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\GenFds.py", line 371, in GenFdsApi > GenFds.GenFd('', FdfParserObj, BuildWorkSpace, ArchList) > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\GenFds.py", line 510, in GenFd > FdObj.GenFd() > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\Fd.py", line 131, in GenFd > RegionObj.AddToBuffer (FdBuffer, self.BaseAddress, self.BlockSizeList= , self.ErasePolarity, GenFdsGlobalVariable.ImageBinDict, self.DefineVarDict= , Flag=3DFlag) > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\Region.py", line 134, in AddToBuffer > FvObj.AddToBuffer(FvBuffer, FvBaseAddress, BlockSize, BlockNum, Erase= Polarity, Flag=3DFlag) > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\Fv.py", line 127, in AddToBuffer > FileName =3D FfsFile.GenFfs(MacroDict, FvParentAddr=3DBaseAddress, Is= Makefile=3DFlag, FvName=3Dself.UiFvName) > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\FfsFileStatement.py", line 156, in GenFfs > sectList, align =3D section.GenSection(OutputDir, self.NameGuid, SecI= ndex, self.KeyStringList, None, Dict) > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\CompressSection.py", line 67, in GenSection > ReturnSectList, AlignValue =3D Sect.GenSection(OutputPath, ModuleName= , SecIndex, KeyStringList, FfsInf, Dict, IsMakefile=3DIsMakefile) > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\UiSection.py", line 70, in GenSection > GenFdsGlobalVariable.GenerateSection(OutputFile, None, 'EFI_SECTION_U= SER_INTERFACE', Ui=3DNameString, IsMakefile=3DIsMakefile) > File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\G= enFds\GenFdsGlobalVariable.py", line 466, in GenerateSection > SectionData.fromstring(Ui.encode("utf_16_le")) > AttributeError: 'array.array' object has no attribute 'fromstring' >=20 --Apple-Mail=_39589A42-4A9A-4429-A45E-09FE1FAA547B Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 Are you using Python 2.7? = Try using Python 3.*

It= looks like array.fromstring() got renamed to array.frombytes() in Python 3= .2, so I=E2=80=99m guessing you are using Python 2.7?
=
Thanks,

Andrew Fish

<= blockquote type=3D"cite" class=3D"">
On Sep 30, 2021, at 1:1= 9 AM, Kumar Jain, Piyush <piyush.kumar.jain@intel.com> wrote:

Traceback (most recent call last):
=
  File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseToo= ls\Source\Python\GenFds\GenFds.py", line 371, in GenFdsApi<= /o:p>
    GenFds.GenFd('', FdfParserObj,= BuildWorkSpace, ArchList)
 = File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\GenF= ds\GenFds.py", line 510, in GenFd
    FdObj.GenFd()
  File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Pyth= on\GenFds\Fd.py", line 131, in GenFd
    RegionObj.AddToBuffer (FdBuffer, self.BaseAddress,= self.BlockSizeList, self.ErasePolarity, GenFdsGlobalVariable.ImageBinDict,= self.DefineVarDict, Flag=3DFlag)
  File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Pyth= on\GenFds\Region.py", line 134, in AddToBuffer
<= div style=3D"margin: 0in; font-size: 11pt; font-family: Calibri, sans-serif= ;" class=3D"">    FvObj.AddToBuffer(FvBuffer, FvBaseAddress,= BlockSize, BlockNum, ErasePolarity, Flag=3DFlag)
  File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseT= ools\Source\Python\GenFds\Fv.py", line 127, in AddToBuffer<= /o:p>
    FileName =3D FfsFile.GenFfs(Ma= croDict, FvParentAddr=3DBaseAddress, IsMakefile=3DFlag, FvName=3Dself.UiFvN= ame)
  File "C:\Users\pkumar= j1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\GenFds\FfsFileStatement.py= ", line 156, in GenFfs
 &nbs= p;  sectList, align =3D section.GenSection(OutputDir, self.NameGuid, S= ecIndex, self.KeyStringList, None, Dict)
  File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Sour= ce\Python\GenFds\CompressSection.py", line 67, in GenSection
    ReturnSectList, AlignValue = =3D Sect.GenSection(OutputPath, ModuleName, SecIndex, KeyStringList, FfsInf= , Dict, IsMakefile=3DIsMakefile)
=   File "C:\Users\pkumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Pytho= n\GenFds\UiSection.py", line 70, in GenSection
<= div style=3D"margin: 0in; font-size: 11pt; font-family: Calibri, sans-serif= ;" class=3D"">    GenFdsGlobalVariable.GenerateSection(Outpu= tFile, None, 'EFI_SECTION_USER_INTERFACE', Ui=3DNameString, IsMakefile=3DIs= Makefile)
  File "C:\Users\p= kumarj1\IFWI3\rocketlake\Edk2\BaseTools\Source\Python\GenFds\GenFdsGlobalVa= riable.py", line 466, in GenerateSection
    SectionData.fromstring(Ui.encode("utf_16_le"))
AttributeError: 'array.array' obje= ct has no attribute 'fromstring'

--Apple-Mail=_39589A42-4A9A-4429-A45E-09FE1FAA547B--