Bug#836520: reprotest: contains a copy of the autopkgtest code

Ximin Luo infinity0 at debian.org
Tue Nov 29 17:18:00 UTC 2016


Hi Martin,

I'm looking into de-duplicating reprotest's embedded copies of autopkgtest code.

In #833407 you said "Using the Python API (adt_testbed.py) is a lot easier and more robust than talking to the backend servers directly", but adt_testbed.py is currently not available as a public Python module. How do you expect users to use it?

Might I suggest you make "/usr/share/autopkgtest/lib" available as a python package? autopkgtest is a fine name for it. I understand you might have some reservations about exposing some "internal" files like this, but the Pythonic way is to prefix those with an underscore (as the stdlib does) and/or document this fact clearly.

By contrast, putting a whole python package into a private path and then hacking sys.path to be able to find this, is not really the appropriate "Pythonic" way to do this. I can certainly sympathise, if you have philosophical problems with Python's approach to module-hiding, but I think this approach is not the best way to fight that fight. Rather, one would try to make a PEP that constructs something clean, that everyone can use.

I've also attached the additional changes that Ceridwen made to the code, since she imported it just before 4.0 was released. I have yet to study it in detail, but feel free to comment in the meantime - if you see any major incompatibilities that would be hard to fix in reprotest, it would be good for me to know quickly and early.

X

On Sat, 3 Sep 2016 13:47:26 -0300 Antonio Terceiro <terceiro at debian.org> wrote:
> Package: reprotest
> Version: 0.2
> Severity: normal
> 
> The virtualization backend binaries provided by autopkgtest are supposed
> to be consumable by external tools¹. Maybe we are not in a point where
> actually doing that is easy/convenient, but having a full copy of the
> autopkgtest code base in reprotest does not seem to be right.
> 
> I even understand how this helped bootstrap the project and made it
> easier at the beginning, but I'm sure you will agree with me that reuse
> by copy-and-paste and embedded code copies are not good ideas.
> 
> ¹ see e.g. https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=833407
> 
> -- System Information:
> Debian Release: stretch/sid
>   APT prefers unstable-debug
>   APT policy: (500, 'unstable-debug'), (500, 'testing-debug'), (500, 'unstable'), (500, 'testing'), (1, 'experimental-debug'), (1, 'experimental')
> Architecture: amd64 (x86_64)
> 
> Kernel: Linux 4.6.0-1-amd64 (SMP w/4 CPU cores)
> Locale: LANG=pt_BR.UTF-8, LC_CTYPE=pt_BR.UTF-8 (charmap=UTF-8)
> Shell: /bin/sh linked to /bin/dash
> Init: systemd (via /run/systemd/system)
> 
> Versions of packages reprotest depends on:
> ii  apt-utils       1.3~rc4
> ii  diffoscope      59
> ii  libdpkg-perl    1.18.10
> ii  procps          2:3.3.12-2
> ii  python3-debian  0.1.29
> pn  python3:any     <none>
> 
> Versions of packages reprotest recommends:
> ii  autodep8     0.8
> ii  disorderfs   0.4.3-1
> ii  locales-all  2.24-1
> ii  qemu-system  1:2.6+dfsg-3
> ii  qemu-utils   1:2.6+dfsg-3
> ii  schroot      1.6.10-2+b1
> 
> reprotest suggests no packages.
> 
> -- no debconf information

-- 
GPG: ed25519/56034877E1F87C35
GPG: rsa4096/1318EFAC5FBBDBCE
https://github.com/infinity0/pubkeys.git
-------------- next part --------------
A non-text attachment was scrubbed...
Name: reprotest-adt.diff
Type: text/x-patch
Size: 3724 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/reproducible-builds/attachments/20161129/2b24362e/attachment.bin>


More information about the Reproducible-builds mailing list