dulwich-users team mailing list archive
-
dulwich-users team
-
Mailing list archive
-
Message #00819
Re: Python 3 porting
Hi all
Progress update from the last email. I worked on fixing all the
"ResourceWarning: unclosed file" warnings when running the test suite
in python 3.4. A pull request for this has been submitted.
(https://github.com/jelmer/dulwich/pull/186)
So as promised, this is my todo list:
* Write an alternative fix for commit b5f3b42ce0 that does not use
universal_newlines as this causes the subprocess files to be decoded.
(rather use os.linesep in test.) Test this on windows. (This is the
next task that I'm going to do.)
* Some api should accept ether bytes or unicode strings (e.g. api that
deals with file paths on disk, e.g. Repo.__init__(path) ) Need to
write a patches for this.
* Split my "Use bytes literals instead of string literals." commit
from my `python3` branch (currently 60002922 ) so that the bytes %
formatting removal is in a separate commit, so that we can land the
other changes separately, and if the bytes % formatting removal does
land, it can be easily reverted at a later stage.
* Look harder for a way to do bytes % formatting in python 3.0 - 3.4.
http://stackoverflow.com/questions/22963526/monkeypatch-pep-461-in-python-3-0-3-4
I would like to have a look at copying the str % format code from
python2, and using it as a ext_module in python3.
* Review the "Use bytes literals instead of string literals." commit
for correctness. Submit pull request.
* Work on getting the test suite pass with the setuptool run 2to3,
(without using six.)
* Look in more detail how feasible it is to get the tutorial doc test
to pass in python 2 and python 3 at the same time.
Regards,
Gary
References