From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.115; helo=mga14.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id A35112118F356 for ; Fri, 16 Nov 2018 07:02:10 -0800 (PST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 16 Nov 2018 07:02:09 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.56,240,1539673200"; d="scan'208,217";a="100833118" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga003.jf.intel.com with ESMTP; 16 Nov 2018 07:02:09 -0800 Received: from fmsmsx119.amr.corp.intel.com (10.18.124.207) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.408.0; Fri, 16 Nov 2018 07:02:09 -0800 Received: from shsmsx102.ccr.corp.intel.com (10.239.4.154) by FMSMSX119.amr.corp.intel.com (10.18.124.207) with Microsoft SMTP Server (TLS) id 14.3.408.0; Fri, 16 Nov 2018 07:02:08 -0800 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.117]) by shsmsx102.ccr.corp.intel.com ([169.254.2.84]) with mapi id 14.03.0415.000; Fri, 16 Nov 2018 23:02:07 +0800 From: "Gao, Liming" To: "edk2-devel@lists.01.org" CC: "Kinney, Michael D" , "leif.lindholm@linaro.org" , "Laszlo Ersek (lersek@redhat.com)" , "afish@apple.com" Thread-Topic: [RFC] Proposal on Python3 Migration Thread-Index: AdR9vPyYzzOqxfgfStKjhSlZIsGdYA== Date: Fri, 16 Nov 2018 15:02:06 +0000 Message-ID: <4A89E2EF3DFEDB4C8BFDE51014F606A14E36DDA6@SHSMSX104.ccr.corp.intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMWU1MGU0Y2UtM2MxYS00MmE3LWI4NGUtMTYyZmExNDM3YjA3IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiT3FxcW9Td21Wdm1XUEdYWGFnOGVRZnU3M0pUdUpEVE44TnIyYnUyZzBOU0I1RDJVUkJXeFhBTWRzdVNCdmhmMSJ9 dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: [RFC] Proposal on Python3 Migration X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Nov 2018 15:02:10 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi, all https://pythonclock.org/ say Python 2.7 will not be maintained past 2020.= One BZ https://bugzilla.tianocore.org/show_bug.cgi?id=3D55 also requests t= his migration. And, Python37 does good performance optimization. In EDK2 bu= ild, Python37 can improve 20% performance than Python27 in Build AutoGen ph= ase. So, we plan to add Python3 support in BaseTools. In previous discussio= n, the feedback is not to drop Python2 support in short term, and keep Pyth= on2 and Python3 coexist. My proposal is to add two copy BaseTools Python code in BaseTools/Source di= rectory. One is current BaseTools/Source/Python, another is new BaseTools/S= ource/Python3. edksetup.bat/edksetup.sh base on environment variable (PYTHO= N3_HOME) to know whether Python3 is used. If PYTHON3_HOME is not set, Pytho= n2 is still used as current way. If user wants to enable Python3, he needs = to set PYTHON3_HOME. After 201811 release tag, BaseTools Python2 source cod= e is kept as the stable release. Python3 is as the active trunk. By default= , any change will be for Python3. If the submitter also request the change = for Python2, he needs to list it in BZ description. If the submitter has th= e clear request, Python2 can add new feature or enhancement. If you have any comments or suggestion on Python3 migration, please join = this discussion. Thanks Liming