From nobody Fri Oct 25 19:39:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=patchew-devel-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=patchew-devel-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1521298047002269.16779262513967; Sat, 17 Mar 2018 07:47:27 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 14C84C0587C2; Sat, 17 Mar 2018 14:47:26 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 010167EE12; Sat, 17 Mar 2018 14:47:26 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id E76A01808800; Sat, 17 Mar 2018 14:47:25 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w2HElPOZ007051 for ; Sat, 17 Mar 2018 10:47:25 -0400 Received: by smtp.corp.redhat.com (Postfix) id 4017A80F65; Sat, 17 Mar 2018 14:47:25 +0000 (UTC) Received: from mx1.redhat.com (ext-mx07.extmail.prod.ext.phx2.redhat.com [10.5.110.31]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 39A5280F60 for ; Sat, 17 Mar 2018 14:47:22 +0000 (UTC) Received: from mail-wr0-f175.google.com (mail-wr0-f175.google.com [209.85.128.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C1984C04BE24 for ; Sat, 17 Mar 2018 14:47:19 +0000 (UTC) Received: by mail-wr0-f175.google.com with SMTP id o8so14384628wra.1 for ; Sat, 17 Mar 2018 07:47:19 -0700 (PDT) Received: from donizetti.lan (94-36-191-219.adsl-ull.clienti.tiscali.it. [94.36.191.219]) by smtp.gmail.com with ESMTPSA id p12sm7724855wre.89.2018.03.17.07.47.15 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 17 Mar 2018 07:47:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=8wXKwZfJAgXvPK8c3eTM79EKnFxJur7wsNKXjl5dwJI=; b=Ly3Tv3PthIlTQelzNcNubWIDNe+sWEHfSqxrRPYdalR/pi42rJuH/HRt3Cro/KyTQ1 h5QmEnXxjhfLaSuVYbNDyMFPMPcRg+3B1B37OqNDHlg8e4ErPQjPly5yqMQlBkcUJi5n XmwgaAkQAGTd+8L0fTuDRkTY07PgnnQ09pdDaOFGpaeI+Qh3EmoqXj/Wr5Q1FWQWDZpw gM9hZDYKecp5yWu8V9v6T8DBJYE/nGLYzRAi4RubHOIXlhLkFR6T6b9E6ZHdFOmxCp8c esNN2qkWTdopRCPa0+L3DZJzm81PG4qsOWhuFn3einLLdZ2XeqRQyePx2FbsEdJ3q1Fu Q1zA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=8wXKwZfJAgXvPK8c3eTM79EKnFxJur7wsNKXjl5dwJI=; b=V7yj8+sgqHI1Nf4qr65OD8B0HryZnLpy1M+s7iiKdmxhROeT52B++CsfAWScdSYzxY NVykQ8QFm5eWd+6ilzHRyvfB1HhLGw4dnh57a89PBDLKnJ3B9G7OkKEOonBkgSylB4gS 2bqz6cw008S1ywN+dNtLL8ANlgYPsRQcuHWxj2H//trI1sSgDjQGcCUj4nHuoLXIlJpk Rer6hk9ZavSB8DVCxDqoAlFxLG6iGj78IR/qmwvrkZEO7FQgSlNEl9R0V5HNWShY+wdg rz3RhxSO5wrBFItC4r9X1shdAjx+A6fCtuqFols9+IKnUDjLJB5qp3gQlGjubLIF/HOX kfkQ== X-Gm-Message-State: AElRT7Hne7shuJEoHyeooGt/8Z3LhxhSAuOxZXORLpjFg42UbVOuJ/Sa /nPe64NhWwrtTBszDfg+stv3ct3X X-Google-Smtp-Source: AG47ELtD38Ay+ApDCEmo6EnJPIrAI5Q8rwCZmQQ/A17jmqzOnoLpO7KiQNweAsxgz4YYoXP0aNRftw== X-Received: by 10.223.138.138 with SMTP id y10mr4270104wry.44.1521298036882; Sat, 17 Mar 2018 07:47:16 -0700 (PDT) From: Paolo Bonzini To: patchew-devel@redhat.com Date: Sat, 17 Mar 2018 15:47:10 +0100 Message-Id: <20180317144714.18268-2-pbonzini@redhat.com> In-Reply-To: <20180317144714.18268-1-pbonzini@redhat.com> References: <20180317144714.18268-1-pbonzini@redhat.com> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Sat, 17 Mar 2018 14:47:19 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Sat, 17 Mar 2018 14:47:19 +0000 (UTC) for IP:'209.85.128.175' DOMAIN:'mail-wr0-f175.google.com' HELO:'mail-wr0-f175.google.com' FROM:'paolo.bonzini@gmail.com' RCPT:'' X-RedHat-Spam-Score: 0.487 (DKIM_SIGNED, DKIM_VALID, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_PASS) 209.85.128.175 mail-wr0-f175.google.com 209.85.128.175 mail-wr0-f175.google.com X-RedHat-Possible-Forgery: Paolo Bonzini X-Scanned-By: MIMEDefang 2.78 on 10.5.110.31 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-loop: patchew-devel@redhat.com Cc: Shubham Jain Subject: [Patchew-devel] [PATCH 1/5] git: include absolute link to log in REST result X-BeenThere: patchew-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Patchew development and discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: patchew-devel-bounces@redhat.com Errors-To: patchew-devel-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Sat, 17 Mar 2018 14:47:26 +0000 (UTC) X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Links in the REST API should be absolute. The next patch will centralize this in the Result object, in the meanwhile fix the git plugin. Signed-off-by: Paolo Bonzini --- mods/git.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/git.py b/mods/git.py index 4fd7dbe..69b5da8 100644 --- a/mods/git.py +++ b/mods/git.py @@ -123,8 +123,8 @@ class GitModule(PatchewModule): git_tag =3D message.get_property("git.tag") data =3D {'repo': git_repo, 'tag': 'refs/tags/' + git_tag} result =3D {'status': 'success', 'data': data} - result['log_url'] =3D reverse("git-log", - kwargs=3D{'series': message.messag= e_id}) + log_url =3D reverse("git-log", kwargs=3D{'series': message.mes= sage_id}) + result['log_url'] =3D request.build_absolute_uri(log_url) else: result =3D {'status': 'pending'} results['git'] =3D result --=20 2.16.2 _______________________________________________ Patchew-devel mailing list Patchew-devel@redhat.com https://www.redhat.com/mailman/listinfo/patchew-devel