From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christopher Baines Subject: Re: Patchwork + automated checking and testing of patches Date: Mon, 19 Nov 2018 19:32:16 +0000 Message-ID: <87in0ssw1r.fsf@cbaines.net> References: <87h8h29z2j.fsf@cbaines.net> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:57868) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gOpHV-0001nu-NE for guix-devel@gnu.org; Mon, 19 Nov 2018 14:32:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gOpHR-0003Rz-Do for guix-devel@gnu.org; Mon, 19 Nov 2018 14:32:25 -0500 Received: from li622-129.members.linode.com ([212.71.249.129]:51644 helo=mira.cbaines.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gOpHR-0003QA-4o for guix-devel@gnu.org; Mon, 19 Nov 2018 14:32:21 -0500 Received: from localhost (cpc102582-walt20-2-0-cust14.13-2.cable.virginm.net [86.27.34.15]) by mira.cbaines.net (Postfix) with ESMTPSA id 78F1D167C9 for ; Mon, 19 Nov 2018 19:32:19 +0000 (GMT) Received: from capella (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id 3e7ae457 for ; Mon, 19 Nov 2018 19:32:19 +0000 (UTC) In-reply-to: <87h8h29z2j.fsf@cbaines.net> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Guix-devel --=-=-= Content-Type: text/plain Christopher Baines writes: > I've now written a very rough package and service for Patchwork [4], and > managed to setup a instance here [5]. With the help of an email account > subscribed to both guix-patches and guix-commits, getmail and a couple > of scripts, it should also collect new patches sent to guix-patches, and > mark those that have been merged to the master branch as "Accepted" [6]. > > 4: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=33185 > 5: https://patchwork.cbaines.net/ > 6: https://patchwork.cbaines.net/project/guix-patches/list/?state=3 So, this has now moved forward a bit since this update. There is a Summary at the bottom which you might want to skip ahead to. I'm now testing out 3 services working together for testing patches: - https://patchwork.cbaines.net/ - https://patchwork-fdo.cbaines.net/ - https://laminar.cbaines.net/ Previously, I was just running Patchwork, and it was just picking up patches from the mailing list, and marking committed patches as accepted. I mailed the Patchwork mailing list [1], as I had a question about re-sending patches, and one thing to come out of that was the realisation that I'd managed to stumble upon the documentation for a fork of Patchwork. 1: https://lists.ozlabs.org/pipermail/patchwork/2018-November/005674.html It turns out that there is a FreeDesktop fork [2][3][4]. It's significant, as I think it does some things better than the upstream version of Patchwork. One example is the Series page. For easy comparison, I'm now running both, so [5] is upstream patchwork, and [6] is the FreeDesktop fork. 2: https://patchwork.freedesktop.org/ 3: https://gitlab.freedesktop.org/patchwork-fdo/patchwork-fdo/ 4: https://patchwork-freedesktop.readthedocs.io/en/latest/ 5: https://patchwork.cbaines.net/ 6: https://patchwork-fdo.cbaines.net/ In addition to that, I wanted to continue working towards testing the patches. Now Patchwork doesn't provide a framework for that, it just provides a way to record the results of the testing. Maybe Cuirass can do this in the future, but for now, I went with writing some bash scripts, using some software called Laminar [1] as a useful framework. It's tagline is "Continuous Integration the Light Way", and it's something I've been wanted to try out for a little while. 7: https://laminar.ohwg.net/ I've configured 3 jobs [8] per patchwork service (fdo is short for FreeDesktop): - patchwork(-fdo)-test-series: To test an individual series of patches. - patchwork(-fdo)-test-new: To trigger the testing of a series for all new (untested or updated) series. - patchwork(-fdo)-test-all: To trigger the testing of all open series, useful when the master branch of guix is updated. 8: https://laminar.cbaines.net/jobs Laminar is configured by some files in /var/lib/laminar/cfg, so I've added some NGinx configuration to make that public here [9]. Currently, the patchwork(-fdo)-test-series jobs just: - Updates it's copy of the guix repository - Downloads the mbox from the relevant patchwork service - Tries applying it - Reports what happened to the relevant patchwork service 9: https://laminar.cbaines.net/cfg/ === Summary === This is still very much a prototype, but I think it's nearing the point where it actually might be doing something useful. Currently, taking the service running the FreeDesktop fork of Patchwork, you can go to the series page [10], and it will show you a list of patch series, along with a indication of the "tests" status, which currently is just whether the patch applied successfully to the master branch. 10: https://patchwork-fdo.cbaines.net/project/guix-patches/series/ The Patchwork service running the upstream code is very similar, you just have to click in to the individual patches to get the information on the "Checks", for an example, have a look at [11] 11: https://patchwork.cbaines.net/patch/233/ Next, I'm planning to work on extending the test series job to actually start running some code, maybe perhaps just applying the patch, and then running make at first. Then maybe trying to use the (guix inferior) module code to intelligently determine changed packages that need building. If you have something that does this, or want to write something to do this, that would be awesome. Any questions or comments, just let me know, Chris --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAlvzD8BfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9Xc6oxAAly4ALkWRYRgxqFkQPMFZ1sbI6N9x3rDmorS0d+nOxLXIAIJgfLJiXK0Q lxVQzdK7+U3SU8HxUAEIQ8wEDG9ehu9feaMpcvAeI/Sx7fsIiMm4MRRP2Ne8Rjxn b60+id25aiWicBLh1Dc6lXCwMaz3ePUoU/se+zZGTgHbW1lvRMe+JIqK/zTzXifb cXhZv1bxajms68iw91jLZx1s8rjep1CCoCCL4qIweLm+8FJOECRwxtDWprEqB/Qq 5oZcSm5oYl8xcyua5cZYyukvEUm0Zm0bet+Z9nossU9CMI5kzlLnod3Xl0SQRYLP fX/EJlvv1eeNuFZ+caLdlq4kIExXjzU1fw5vG5elzh6aK6dFdwoo18+zuzMAc/DD PAPSHydQdwGoZb7Vm1lhvCL9l25aCWplGnh22KiF1woId+Z4TsUrgk1rkHs52XIn BrPDe6cGp9TqBdLzxiRXNvur68mU/Hii5S9Z+lpxHN+Y3n1CUR/+DEGjpJmWi20I SNrP2nNKYE83hd872Uxjz59Nf13FWVKhLOBXMoWxLJyXNOPQeeB2FxGQJ1WSiRSX Yjw20jeV+enIwoK27SZYJ9U/V5oxgEXmUJ5UuolfF72OaGnmSPofWegOErqo3nw0 xPDI/I8JTr8uJCuXwWNtGoVHXONfHsK7jfHOJSvVbnMZ8H/5ezE= =ymst -----END PGP SIGNATURE----- --=-=-=--