[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#904776: /usr/bin/dpkg-source: please parse d/t/control.autodep8 like d/t/control


[ Please excuse some of the probably obvious questions, I probably
  just do not have a clear picture of how the pieces fit together. ]

On Mon, 2018-07-30 at 20:03:07 +0200, Paul Gevers wrote:
> On 30-07-18 05:42, Guillem Jover wrote:
> >> It would be great if dpkg-source would also parse debian/tests/control.autodep8
> >> in the same way as it does debian/tests/control, except I guess it should not
> >> set the Testsuite field (as dpkg-source doesn't know which type of autopkgtest
> >> this is).
> > 
> > Hmm, why did we get this new file at all?
> It's more than two years old. It was added in response to bug 823931.

Would you be open to revisit that decision? The current interface
feels a bit like a wart to me. It didn't look like there were many
packages involved, when I checked the other day.

> > Why can't we use
> > debian/tests/control instead? The Testsuite field would be used to
> > specify that we still want autodep8 to be run, no?
> Looking at the bug, I can only assume it just wasn't considered to
> change autopkgtest, e.g. IIAC the maintainer of autodep8 wasn't a
> developer of autopkgtest at the time.

Well, autodep8 seems to be called from autopkgtest, so I'm not sure I
understand that reason? :)

> Also, the current implementation works without the spec needing to
> mention the debian/control file.

Isn't it implicitly mentioned in the “Source package header” section?

> autopkgtest (the binary that is _an_
> implementation of the spec) only calls autodep8 when it doesn't find the
> control file as a fall back. autopkgtest doesn't know why it is called,
> it doesn't know about the Testsuite field, nor does anything in the CI
> framework except for the one that requests the test.

Right, but it seems autodep8 does check, and uses the Testsuite field
to decide whether some of the precooked checks should be used.

Wouldn't simply changing the logic to something like the following
simplified stuff, do the trick?

  * change autopkgtest to always call autodep8 if auto_control is
  * change autodep8 to always cat debian/tests/control if present.
  * then autodep8 would cat the autogenerated tests like now based on
    the Testsuite field, and for backwards compat also the
    control.autodep8 file if present.

Maybe this new mode of operation would be selected via a new
command-line option, dunno.

> If we would want to add support for this adding autodep8 on top of an
> existing debian/tests/control file, apart from adapting autopkgtest with
> a new option, also multiple interface would need to be adapted to pass
> on this info:
> britney <-> debci <-> autopkgtest

Why is that, what information do these require?


Reply to: