On 2019-09-02 11:03, Joachim Breitner wrote:
Am Montag, den 02.09.2019, 10:57 +0200 schrieb Philipp Kern:
FWIW, I started working on this. Unfortunately we do not really have
transactions available to schedule all or nothing. If someone has a
creative idea on how to best signal back partial success, let me know.
:)
(My current best guess is a JSON file served as an attachment to the
API
call with success/failure states...)
The JSON is for the response status, and the request will be the
existing format as seen in
https://people.debian.org/~nomeata/binNMUs-haskell.txt
right?
Right now my guide rail is https://buildd.debian.org/auth/giveback.cgi
(documented in [1]) which spews out a bunch of validation notices and
then performs the action.
I would prefer JSON as an input format, looking roughly like this:
[{"pkg": "haskell-active", "ver": "0.2.0.13-6", "archs": ["mipsel",
"mips64el"], "suite": "sid", "reason": "semigroupoids changed from 5.2.2
to 5.3.2"}]
The rationale for this is that it is way easier for me to validate the
input if presented this way. As we know the output of your script above
is piped into wb, which is a glorified wrapper around wanna-build doing
some of the lifting required. Rather than trying to make sense of a line
that is an input to another script (which also supports different
actions), it seems better to constrain us down in a way where every
field is explicitly presented. Especially as ultimately everything needs
to be passed to another binary through command-line options.
The output is then yet another question to solve...
Kind regards
Philipp Kern
[1]
https://debblog.philkern.de/2019/08/alpha-self-service-buildd-givebacks.html