[Piuparts-devel] First step to Python 3

Herbert Fortes terberh at gmail.com
Tue Jan 15 15:53:16 GMT 2019


On 1/15/19 1:31 PM, Holger Levsen wrote:
> On Mon, Jan 14, 2019 at 01:29:36PM -0200, Herbert Fortes wrote:
>>>> python-lzma seems to be for tests too (piupartslib/__init__.py).
>>>> piuparts-common package has it for 'Depends'.
>>> what's your question/comment here?
>> Piuparts does not need python-lzma
> 
> but the test do need it?
> 
>> I ran tests (nosetestes3) without python-lzma. 
> 
> ah. so we can drop the python-lzma depends?

I belive yes

> 
>> I
>> think I have Python2  installed because of xmlto.
>>
>> xmlto started to be necessary in version 0.36.
>>
>> - add build-dependencies on debhelper, asciidoc and xmlto.
>> - remove build-dependencies on docbook2x and docbook-xml.
>>
>> If Piuparts stop to use xmlto package it will not
>> need Python2.
> 
> I guess xmlto will need to be ported to python3 then?

I am wrong. asciidoc*[0] seems to be the problem:


# apt purge python2.7-minimal
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  asciidoc-common asciidoc-doc dblatex-doc fonts-gfs-baskerville
  fonts-gfs-porson libmime-charset-perl libpython-stdlib libpython2-stdlib
  libsgmls-perl libsombok3 libunicode-linebreak-perl libyaml-tiny-perl
  preview-latex-style sgmlspl tcl teckit texlive texlive-bibtex-extra
  texlive-lang-greek texlive-plain-generic tk vim-addon-manager vim-asciidoc
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
  asciidoc* asciidoc-base* asciidoc-dblatex* dblatex* docbook-utils* python*
  [...]

[0] - https://packages.debian.org/sid/asciidoc-base




>>    (doc files can wait)
> 
> well, we need those doc files...
> 
> Thanks for all your work on this! Really very much appreciated!

Good! I am really enjoying it. There is more work to do. Like
a review/cleanning:
 
./master-bin/detect_well_known_errors.py:
        [os.mkdir(x) for x in workdirs if not os.path.exists(x)]

It is to make dirs only. It can be '()' instead of '[]', I guess.

piuparts.py
 for vfile in files[:]:

The '[:]'.

./piuparts-master-backend.py:            if len(parts) > 0:


Maybe an 'import' that is not used anymore. Have to check these.
flake8, isort.



Regards,
Herbert






More information about the Piuparts-devel mailing list