get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/1523264/
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 1523264,
    "url": "http://patchwork.ozlabs.org/api/patches/1523264/",
    "web_url": "http://patchwork.ozlabs.org/project/openvswitch/patch/20210901161526.237479-1-twilson@redhat.com/",
    "project": {
        "id": 47,
        "url": "http://patchwork.ozlabs.org/api/projects/47/",
        "name": "Open vSwitch",
        "link_name": "openvswitch",
        "list_id": "ovs-dev.openvswitch.org",
        "list_email": "ovs-dev@openvswitch.org",
        "web_url": "http://openvswitch.org/",
        "scm_url": "git@github.com:openvswitch/ovs.git",
        "webscm_url": "https://github.com/openvswitch/ovs",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20210901161526.237479-1-twilson@redhat.com>",
    "list_archive_url": null,
    "date": "2021-09-01T16:15:26",
    "name": "[ovs-dev,python] Avoid sending transactions when the DB is not synced up",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "6e1ce9034935aafc1f9b164b5dd961abe7a772e2",
    "submitter": {
        "id": 68630,
        "url": "http://patchwork.ozlabs.org/api/people/68630/",
        "name": "Terry Wilson",
        "email": "twilson@redhat.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/openvswitch/patch/20210901161526.237479-1-twilson@redhat.com/mbox/",
    "series": [
        {
            "id": 260592,
            "url": "http://patchwork.ozlabs.org/api/series/260592/",
            "web_url": "http://patchwork.ozlabs.org/project/openvswitch/list/?series=260592",
            "date": "2021-09-01T16:15:26",
            "name": "[ovs-dev,python] Avoid sending transactions when the DB is not synced up",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/260592/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/1523264/comments/",
    "check": "success",
    "checks": "http://patchwork.ozlabs.org/api/patches/1523264/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<ovs-dev-bounces@openvswitch.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "dev@openvswitch.org"
        ],
        "Delivered-To": [
            "patchwork-incoming@bilbo.ozlabs.org",
            "ovs-dev@lists.linuxfoundation.org"
        ],
        "Authentication-Results": [
            "ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=mimecast20190719 header.b=One+V5Mm;\n\tdkim-atps=neutral",
            "ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org\n (client-ip=2605:bc80:3010::138; helo=smtp1.osuosl.org;\n envelope-from=ovs-dev-bounces@openvswitch.org; receiver=<UNKNOWN>)",
            "smtp2.osuosl.org (amavisd-new);\n dkim=pass (1024-bit key) header.d=redhat.com",
            "relay.mimecast.com;\n auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=twilson@redhat.com"
        ],
        "Received": [
            "from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest\n SHA256)\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 4H08LG2y1Xz9sX3\n\tfor <incoming@patchwork.ozlabs.org>; Thu,  2 Sep 2021 02:15:50 +1000 (AEST)",
            "from localhost (localhost [127.0.0.1])\n\tby smtp1.osuosl.org (Postfix) with ESMTP id 759F080D4A;\n\tWed,  1 Sep 2021 16:15:47 +0000 (UTC)",
            "from smtp1.osuosl.org ([127.0.0.1])\n\tby localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id UJ8fWQVSOO5H; Wed,  1 Sep 2021 16:15:43 +0000 (UTC)",
            "from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56])\n\tby smtp1.osuosl.org (Postfix) with ESMTPS id D154580D51;\n\tWed,  1 Sep 2021 16:15:42 +0000 (UTC)",
            "from lf-lists.osuosl.org (localhost [127.0.0.1])\n\tby lists.linuxfoundation.org (Postfix) with ESMTP id A4329C0010;\n\tWed,  1 Sep 2021 16:15:42 +0000 (UTC)",
            "from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133])\n by lists.linuxfoundation.org (Postfix) with ESMTP id 7E563C000E\n for <dev@openvswitch.org>; Wed,  1 Sep 2021 16:15:41 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n by smtp2.osuosl.org (Postfix) with ESMTP id 6002E40158\n for <dev@openvswitch.org>; Wed,  1 Sep 2021 16:15:41 +0000 (UTC)",
            "from smtp2.osuosl.org ([127.0.0.1])\n by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n with ESMTP id IzsyBmakBTvk for <dev@openvswitch.org>;\n Wed,  1 Sep 2021 16:15:37 +0000 (UTC)",
            "from us-smtp-delivery-124.mimecast.com\n (us-smtp-delivery-124.mimecast.com [170.10.133.124])\n by smtp2.osuosl.org (Postfix) with ESMTPS id 1077E40146\n for <dev@openvswitch.org>; Wed,  1 Sep 2021 16:15:36 +0000 (UTC)",
            "from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com\n [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id\n us-mta-376-kje-phn4MjKEQWfYLntyRw-1; Wed, 01 Sep 2021 12:15:34 -0400",
            "from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com\n [10.5.11.12])\n (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n (No client certificate requested)\n by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EF529102CB80\n for <dev@openvswitch.org>; Wed,  1 Sep 2021 16:15:33 +0000 (UTC)",
            "from centos8.localdomain (unknown [10.22.18.225])\n by smtp.corp.redhat.com (Postfix) with ESMTP id 957C360C05;\n Wed,  1 Sep 2021 16:15:33 +0000 (UTC)"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.8.0",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n s=mimecast20190719; t=1630512935;\n h=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n to:to:cc:cc:mime-version:mime-version:content-type:content-type:\n content-transfer-encoding:content-transfer-encoding;\n bh=NcADywkrHwVD8XGqk2YI0/YOW5ozlhUMVVgFvmPpoHQ=;\n b=One+V5MmKqKzjq9vNmNka6pZ7orhGBE71b0YxdWFb0anuh4D2UAkOSO1sK7ZfdjOzIVYGZ\n yodSK9zWiJ9+WHuXl718CzmuZeAGPDE5xAm1v/bTAhRxSSYsSnm7lTtFbSfeUnTBMAQyh9\n ncq41q3QpA75NKvN+rvi2SeOMh/jf1M=",
        "X-MC-Unique": "kje-phn4MjKEQWfYLntyRw-1",
        "From": "Terry Wilson <twilson@redhat.com>",
        "To": "dev@openvswitch.org",
        "Date": "Wed,  1 Sep 2021 16:15:26 +0000",
        "Message-Id": "<20210901161526.237479-1-twilson@redhat.com>",
        "MIME-Version": "1.0",
        "X-Scanned-By": "MIMEDefang 2.79 on 10.5.11.12",
        "X-Mimecast-Spam-Score": "0",
        "X-Mimecast-Originator": "redhat.com",
        "Subject": "[ovs-dev] [PATCH] [python] Avoid sending transactions when the DB\n\tis not synced up",
        "X-BeenThere": "ovs-dev@openvswitch.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "<ovs-dev.openvswitch.org>",
        "List-Unsubscribe": "<https://mail.openvswitch.org/mailman/options/ovs-dev>,\n <mailto:ovs-dev-request@openvswitch.org?subject=unsubscribe>",
        "List-Archive": "<http://mail.openvswitch.org/pipermail/ovs-dev/>",
        "List-Post": "<mailto:ovs-dev@openvswitch.org>",
        "List-Help": "<mailto:ovs-dev-request@openvswitch.org?subject=help>",
        "List-Subscribe": "<https://mail.openvswitch.org/mailman/listinfo/ovs-dev>,\n <mailto:ovs-dev-request@openvswitch.org?subject=subscribe>",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "ovs-dev-bounces@openvswitch.org",
        "Sender": "\"dev\" <ovs-dev-bounces@openvswitch.org>"
    },
    "content": "This ports the C IDL change f50714b to the Python IDL:\n\nUntil now the code here would happily try to send transactions to the\ndatabase server even if the database connection was not in the correct\nstate.  In some cases this could lead to strange behavior, such as sending\na database transaction for a database that the IDL had just learned did not\nexist on the server.\n\nSigned-off-by: Terry Wilson <twilson@redhat.com>\n---\n python/ovs/db/idl.py | 6 ++++++\n 1 file changed, 6 insertions(+)",
    "diff": "diff --git a/python/ovs/db/idl.py b/python/ovs/db/idl.py\nindex ecae5e143..0be0064de 100644\n--- a/python/ovs/db/idl.py\n+++ b/python/ovs/db/idl.py\n@@ -1500,6 +1500,12 @@ class Transaction(object):\n         the IDL's copy of the database.  If the transaction commits\n         successfully, then the database server will send an update and, thus,\n         the IDL will be updated with the committed changes.\"\"\"\n+\n+        if self.idl.state != Idl.IDL_S_MONITORING:\n+            self._status = Transaction.TRY_AGAIN\n+            self.__disassemble()\n+            return self._status\n+\n         # The status can only change if we're the active transaction.\n         # (Otherwise, our status will change only in Idl.run().)\n         if self != self.idl.txn:\n",
    "prefixes": [
        "ovs-dev",
        "python"
    ]
}