Show a patch.

GET /api/1.1/patches/21808/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 21808,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/21808/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/21808/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/1.1/projects/1/?format=api",
        "name": "libcamera",
        "link_name": "libcamera",
        "list_id": "libcamera_core",
        "list_email": "libcamera-devel@lists.libcamera.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20241105000703.22037-1-laurent.pinchart@ideasonboard.com>",
    "date": "2024-11-05T00:07:03",
    "name": "test: py: Fix log level restore in SimpleTestMethods()",
    "commit_ref": "876730d805bb48ac0b458f557b09f66eb0c694d5",
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "d18368d197d6201d143d23825b9465dceb387af4",
    "submitter": {
        "id": 2,
        "url": "https://patchwork.libcamera.org/api/1.1/people/2/?format=api",
        "name": "Laurent Pinchart",
        "email": "laurent.pinchart@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/21808/mbox/",
    "series": [
        {
            "id": 4767,
            "url": "https://patchwork.libcamera.org/api/1.1/series/4767/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=4767",
            "date": "2024-11-05T00:07:03",
            "name": "test: py: Fix log level restore in SimpleTestMethods()",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/4767/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/21808/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/21808/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<libcamera-devel-bounces@lists.libcamera.org>",
        "X-Original-To": "parsemail@patchwork.libcamera.org",
        "Delivered-To": "parsemail@patchwork.libcamera.org",
        "Received": [
            "from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 8C3DFBDC71\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue,  5 Nov 2024 00:07:11 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id D7881653E4;\n\tTue,  5 Nov 2024 01:07:10 +0100 (CET)",
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 2A88E65399\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue,  5 Nov 2024 01:07:09 +0100 (CET)",
            "from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id C091F4AD;\n\tTue,  5 Nov 2024 01:07:01 +0100 (CET)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"SBuNZjc5\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1730765222;\n\tbh=GUw4bQkbQvtCe4JBfPFK9EkKFmmbvDQmfKm5TIHNVZc=;\n\th=From:To:Cc:Subject:Date:From;\n\tb=SBuNZjc5osugRk3PRr/p4NsuzDXFqgxCYt2GNZQ1KfV8gYvvrIkcy4szisOfl9gzq\n\tTOFw+pobbIe8C/so1FoWJLUDlVylCjDz8s9mCnmXCxFzbuQYfVGShhtosGoJYB+nJJ\n\tyQJni0nAuVzh24nHody1lfimafw8JMw6xZdx19F8=",
        "From": "Laurent Pinchart <laurent.pinchart@ideasonboard.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Cc": "Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>",
        "Subject": "[PATCH] test: py: Fix log level restore in SimpleTestMethods()",
        "Date": "Tue,  5 Nov 2024 02:07:03 +0200",
        "Message-ID": "<20241105000703.22037-1-laurent.pinchart@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.45.2",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-BeenThere": "libcamera-devel@lists.libcamera.org",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "<libcamera-devel.lists.libcamera.org>",
        "List-Unsubscribe": "<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>",
        "List-Archive": "<https://lists.libcamera.org/pipermail/libcamera-devel/>",
        "List-Post": "<mailto:libcamera-devel@lists.libcamera.org>",
        "List-Help": "<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>",
        "List-Subscribe": "<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "The SimpleTestMethods() function tests that incorrect calls to the\nCamera.acquire() method raise an exception. Before doing so, it sets the\nlog level for the Camera category to FATAL, in order to avoid showing\nmisleading errors in the test log, and then restores the log level to\nERROR after running the test. ERROR is however not the default log\nlevel. Restore the log level to INFO instead, in order to avoid losing\nlog messages in subsequent tests.\n\nFixes: 06cb7130c4fa (\"py: Add unittests.py\")\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n test/py/unittests.py | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\n\nbase-commit: f028b09b7becf4e7847112b2e8044e5e30e01c58",
    "diff": "diff --git a/test/py/unittests.py b/test/py/unittests.py\nindex 1caea98eb946..8cb850d4e71c 100755\n--- a/test/py/unittests.py\n+++ b/test/py/unittests.py\n@@ -66,7 +66,7 @@ class SimpleTestMethods(BaseTestCase):\n         libcam.log_set_level('Camera', 'FATAL')\n         with self.assertRaises(RuntimeError):\n             cam.acquire()\n-        libcam.log_set_level('Camera', 'ERROR')\n+        libcam.log_set_level('Camera', 'INFO')\n \n         cam.release()\n \n",
    "prefixes": []
}