* [Patch] BaseTools Python: Migrate Python27 to Python36 @ 2018-09-26 13:02 Zhu, Yonghong 2018-10-01 10:23 ` Gary Lin 0 siblings, 1 reply; 4+ messages in thread From: Zhu, Yonghong @ 2018-09-26 13:02 UTC (permalink / raw) To: edk2-devel@lists.01.org Cc: Feng, YunhuaX, Sun, Yanyan, Chen, Hesheng, Zhao, ZhiqiangX, Feng, Bob C, Zhu, Yonghong Hi All, Now we are working on bugzilla 55<https://bugzilla.tianocore.org/show_bug.cgi?id=55> (https://bugzilla.tianocore.org/show_bug.cgi?id=55) to migrate BaseTools python tool from Python27 to Python36. After this migration, the BaseTools will only support Python 3. And for now, user need to install a Python version >= 3.6. Here is the link: https://github.com/yzhu52/edk2.git Branch: Python3_V2 In this branch, after run edksetup script file, tool auto detect the Python tool that version >= 3.6, tool would report error if it can't find the python that >= 3.6. Current we still in doing some validation for this migration, and not finish the update for UPT, ECC, EOT, Tests those tools and scripts. We already did following on this branch: 1. Remove the "from __future__ import" items 2. Update the xrange to range 3. Update long to int 4. Use input instead of raw_input 5. Not use iteritems(), but use items() directly 6. Remove the super() function argument 7. Remove the itertools usage 8. Fix some open file's read and write function 9. Hand the bytes and str type difference 10. Do some list and iterator update 11. Change the division operation in the expression 12. Use '\n' but not os.linesep 13. Update the BinWrappers script 14. Update edksetup script file Your suggestions is highly appreciated. Best Regards, Zhu Yonghong ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Patch] BaseTools Python: Migrate Python27 to Python36 2018-09-26 13:02 [Patch] BaseTools Python: Migrate Python27 to Python36 Zhu, Yonghong @ 2018-10-01 10:23 ` Gary Lin 2018-10-01 15:13 ` Kinney, Michael D 0 siblings, 1 reply; 4+ messages in thread From: Gary Lin @ 2018-10-01 10:23 UTC (permalink / raw) To: Zhu, Yonghong; +Cc: edk2-devel@lists.01.org, Chen, Hesheng, Sun, Yanyan On Wed, Sep 26, 2018 at 01:02:05PM +0000, Zhu, Yonghong wrote: > Hi All, > Hi Yonghong, > Now we are working on bugzilla 55<https://bugzilla.tianocore.org/show_bug.cgi?id=55> (https://bugzilla.tianocore.org/show_bug.cgi?id=55) to migrate BaseTools python tool from Python27 to Python36. After this migration, the BaseTools will only support Python 3. And for now, user need to install a Python version >= 3.6. > Here is the link: https://github.com/yzhu52/edk2.git Branch: Python3_V2 > In this branch, after run edksetup script file, tool auto detect the Python tool that version >= 3.6, tool would report error if it can't find the python that >= 3.6. > I'm testing the branch and found a minor bug in edksetup.sh that caused OvmfPkg/build.sh failed to build. I wrote a patch and it works for me. Where should I send the patch? to the edk2-devel mailinglist directly? or a pull request in github? Thanks, Gary Lin > Current we still in doing some validation for this migration, and not finish the update for UPT, ECC, EOT, Tests those tools and scripts. > We already did following on this branch: > > 1. Remove the "from __future__ import" items > > 2. Update the xrange to range > > 3. Update long to int > > 4. Use input instead of raw_input > > 5. Not use iteritems(), but use items() directly > > 6. Remove the super() function argument > > 7. Remove the itertools usage > > 8. Fix some open file's read and write function > > 9. Hand the bytes and str type difference > > 10. Do some list and iterator update > > 11. Change the division operation in the expression > > 12. Use '\n' but not os.linesep > > 13. Update the BinWrappers script > > 14. Update edksetup script file > > > Your suggestions is highly appreciated. > > Best Regards, > Zhu Yonghong > > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel > ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Patch] BaseTools Python: Migrate Python27 to Python36 2018-10-01 10:23 ` Gary Lin @ 2018-10-01 15:13 ` Kinney, Michael D 2018-10-09 8:57 ` Zhu, Yonghong 0 siblings, 1 reply; 4+ messages in thread From: Kinney, Michael D @ 2018-10-01 15:13 UTC (permalink / raw) To: Gary Lin, Zhu, Yonghong, Kinney, Michael D Cc: Sun, Yanyan, edk2-devel@lists.01.org, Chen, Hesheng Gary, Please send the patch to edk2-devel. Yonghong may not be available much this week, so you may not see a response form him till next week. Thanks, Mike > -----Original Message----- > From: edk2-devel [mailto:edk2-devel- > bounces@lists.01.org] On Behalf Of Gary Lin > Sent: Monday, October 1, 2018 3:24 AM > To: Zhu, Yonghong <yonghong.zhu@intel.com> > Cc: Sun, Yanyan <yanyan.sun@intel.com>; edk2- > devel@lists.01.org; Chen, Hesheng > <hesheng.chen@intel.com> > Subject: Re: [edk2] [Patch] BaseTools Python: Migrate > Python27 to Python36 > > On Wed, Sep 26, 2018 at 01:02:05PM +0000, Zhu, Yonghong > wrote: > > Hi All, > > > Hi Yonghong, > > > Now we are working on bugzilla > 55<https://bugzilla.tianocore.org/show_bug.cgi?id=55> > (https://bugzilla.tianocore.org/show_bug.cgi?id=55) to > migrate BaseTools python tool from Python27 to > Python36. After this migration, the BaseTools will > only support Python 3. And for now, user need to > install a Python version >= 3.6. > > Here is the link: https://github.com/yzhu52/edk2.git > Branch: Python3_V2 > > In this branch, after run edksetup script file, tool > auto detect the Python tool that version >= 3.6, tool > would report error if it can't find the python that >= > 3.6. > > > I'm testing the branch and found a minor bug in > edksetup.sh that caused > OvmfPkg/build.sh failed to build. I wrote a patch and > it works for me. > Where should I send the patch? to the edk2-devel > mailinglist directly? > or a pull request in github? > > Thanks, > > Gary Lin > > > Current we still in doing some validation for this > migration, and not finish the update for UPT, ECC, EOT, > Tests those tools and scripts. > > We already did following on this branch: > > > > 1. Remove the "from __future__ import" items > > > > 2. Update the xrange to range > > > > 3. Update long to int > > > > 4. Use input instead of raw_input > > > > 5. Not use iteritems(), but use items() > directly > > > > 6. Remove the super() function argument > > > > 7. Remove the itertools usage > > > > 8. Fix some open file's read and write function > > > > 9. Hand the bytes and str type difference > > > > 10. Do some list and iterator update > > > > 11. Change the division operation in the expression > > > > 12. Use '\n' but not os.linesep > > > > 13. Update the BinWrappers script > > > > 14. Update edksetup script file > > > > > > Your suggestions is highly appreciated. > > > > Best Regards, > > Zhu Yonghong > > > > _______________________________________________ > > edk2-devel mailing list > > edk2-devel@lists.01.org > > https://lists.01.org/mailman/listinfo/edk2-devel > > > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Patch] BaseTools Python: Migrate Python27 to Python36 2018-10-01 15:13 ` Kinney, Michael D @ 2018-10-09 8:57 ` Zhu, Yonghong 0 siblings, 0 replies; 4+ messages in thread From: Zhu, Yonghong @ 2018-10-09 8:57 UTC (permalink / raw) To: Kinney, Michael D, Gary Lin, edk2-devel@lists.01.org Cc: Sun, Yanyan, Chen, Hesheng, Zhu, Yonghong Hi All, If no more comment, I hope to sync Python3 migration patches to edk2 master in this week. Thanks. Best Regards, Zhu Yonghong -----Original Message----- From: Kinney, Michael D Sent: Monday, October 01, 2018 11:14 PM To: Gary Lin <glin@suse.com>; Zhu, Yonghong <yonghong.zhu@intel.com>; Kinney, Michael D <michael.d.kinney@intel.com> Cc: Sun, Yanyan <yanyan.sun@intel.com>; edk2-devel@lists.01.org; Chen, Hesheng <hesheng.chen@intel.com> Subject: RE: [edk2] [Patch] BaseTools Python: Migrate Python27 to Python36 Gary, Please send the patch to edk2-devel. Yonghong may not be available much this week, so you may not see a response form him till next week. Thanks, Mike > -----Original Message----- > From: edk2-devel [mailto:edk2-devel- > bounces@lists.01.org] On Behalf Of Gary Lin > Sent: Monday, October 1, 2018 3:24 AM > To: Zhu, Yonghong <yonghong.zhu@intel.com> > Cc: Sun, Yanyan <yanyan.sun@intel.com>; edk2- devel@lists.01.org; > Chen, Hesheng <hesheng.chen@intel.com> > Subject: Re: [edk2] [Patch] BaseTools Python: Migrate > Python27 to Python36 > > On Wed, Sep 26, 2018 at 01:02:05PM +0000, Zhu, Yonghong > wrote: > > Hi All, > > > Hi Yonghong, > > > Now we are working on bugzilla > 55<https://bugzilla.tianocore.org/show_bug.cgi?id=55> > (https://bugzilla.tianocore.org/show_bug.cgi?id=55) to migrate > BaseTools python tool from Python27 to Python36. After this > migration, the BaseTools will only support Python 3. And for now, user > need to install a Python version >= 3.6. > > Here is the link: https://github.com/yzhu52/edk2.git > Branch: Python3_V2 > > In this branch, after run edksetup script file, tool > auto detect the Python tool that version >= 3.6, tool would report > error if it can't find the python that >= 3.6. > > > I'm testing the branch and found a minor bug in edksetup.sh that > caused OvmfPkg/build.sh failed to build. I wrote a patch and it works > for me. > Where should I send the patch? to the edk2-devel mailinglist directly? > or a pull request in github? > > Thanks, > > Gary Lin > > > Current we still in doing some validation for this > migration, and not finish the update for UPT, ECC, EOT, Tests those > tools and scripts. > > We already did following on this branch: > > > > 1. Remove the "from __future__ import" items > > > > 2. Update the xrange to range > > > > 3. Update long to int > > > > 4. Use input instead of raw_input > > > > 5. Not use iteritems(), but use items() > directly > > > > 6. Remove the super() function argument > > > > 7. Remove the itertools usage > > > > 8. Fix some open file's read and write function > > > > 9. Hand the bytes and str type difference > > > > 10. Do some list and iterator update > > > > 11. Change the division operation in the expression > > > > 12. Use '\n' but not os.linesep > > > > 13. Update the BinWrappers script > > > > 14. Update edksetup script file > > > > > > Your suggestions is highly appreciated. > > > > Best Regards, > > Zhu Yonghong > > > > _______________________________________________ > > edk2-devel mailing list > > edk2-devel@lists.01.org > > https://lists.01.org/mailman/listinfo/edk2-devel > > > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-10-09 8:58 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2018-09-26 13:02 [Patch] BaseTools Python: Migrate Python27 to Python36 Zhu, Yonghong 2018-10-01 10:23 ` Gary Lin 2018-10-01 15:13 ` Kinney, Michael D 2018-10-09 8:57 ` Zhu, Yonghong
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox